cleaning track numbers


I have a heap of track numbers that include the total tracks in the track field.

eg, some tracks are simple 1, 2, 3, 4... others are 1/12, 2/12, 3/12, 4/12...

I want to remove them and populate it with simply the track number and move the total number of tracks to the total tracks field, but I don't know how to do this

For the first part I tried creating an action that formatted a field based on TRACK, but it returns a blank whether there is a "/" or not, can anyone see what it is I am doing wrong?


Thanks in advance


and I just found a similar thread, so I used the solution from

Rename from tag (fractional track numbers)

to simply: $num(%track%,1) and the trailing part is stripped...