This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

A solution for combining/merging two TCX files (activies)

Former Member
Former Member
This weekend I needed to adjust my interval workout while it was in progress (yes, I needed a break!) This resulted in me having two different activities and two TCX files for each.

I searched and downloaded various software, but they didn't do exactly what I wanted. (Some didn't preserve the calories, and some turned the workout into a course, etc)

I then tried just copying all the laps from one TCX to the other using notepad, but that didn't work either. The distance was corrupt when I uploaded to Garmin Connect. I realized that the the individual laps in each activity have a cumulative distance tracker. So all I needed to do to make this work is offset the last distance tracked to all of the distances from the other activity.

I created a simple XSLT transform that can be applied to two TCX files and it will create a new merged activity.

Thought I'd share.

(Note, you'll need a XSLT processor like saxon/xalan or others)
  • Great tool ! Thanks so much !
  • Former Member
    0 Former Member over 11 years ago
    I just whipped up a quick and dirty Java program that is self contained and easy to execute.

    Make sure you have Java installed, then...

    Download this .jar file, and then double click it.

    CombineActivities.jar


    Thanks for this. I have used it successfully for 2 files a few times. However I now want to combine 10 activities. Is there anyway to use this for more than 2...?
  • Just used this 7/2/2014 and it is quick and very easy to use. Thank you ever so much!
    I just whipped up a quick and dirty Java program that is self contained and easy to execute.

    Make sure you have Java installed, then...

    Download this .jar file, and then double click it.

    CombineActivities.jar
  • Former Member
    0 Former Member over 11 years ago
    Hi,

    I have been trying to solve my little problem for a week now but I have to give up. I am hoping that someone here would be a bit more handy with my files and find a way to merge them successfully.

    I recorded my ride with Wahoo Fitness iPhone app and for some reason the gps data was not recorded this time. Everything else is in the tcx file (speed, cadence, hr). I have now created manually the exact route I rode and I would like to combine these two files into one.

    https://www.dropbox.com/s/wmhqdnteneefqxa/The%20Ride.tcx

    https://www.dropbox.com/s/fadyj9700mjuxd1/The%20Route.tcx

    Thanks,
    D
  • Former Member
    0 Former Member over 11 years ago
    Worked great. Thanks.
  • Former Member
    0 Former Member over 11 years ago
    Hi,

    I have been trying to solve my little problem for a week now but I have to give up. I am hoping that someone here would be a bit more handy with my files and find a way to merge them successfully.

    I recorded my ride with Wahoo Fitness iPhone app and for some reason the gps data was not recorded this time. Everything else is in the tcx file (speed, cadence, hr). I have now created manually the exact route I rode and I would like to combine these two files into one.

    https://www.dropbox.com/s/wmhqdnteneefqxa/The%20Ride.tcx

    https://www.dropbox.com/s/fadyj9700mjuxd1/The%20Route.tcx

    Thanks,
    D



    Hello Dan,

    This is an old post but I fixed your file anyway just in case.

    So....here ya go. Fixed with the Fit File Repair Tool.

    https://www.dropbox.com/s/tk8eyew6jd8ghiq/The%20Ride-fixed01.zip
  • Former Member
    0 Former Member over 10 years ago
    Brilliant

    Thank you for the TCX advice. I had a run interrupted today when trying to help someone catch an injured sea eagle. Combining the two files worked and now uploaded.
  • I just went looking for a solution after interrupting a run on my Garmin inadvertently and found CombineActivities.jar here. What an easy solution. It took hardly any time at all to accomplish what I needed. Thanks!
  • Former Member
    0 Former Member over 10 years ago
    I have a Forerunner for my HRM and an etrex Vista HCx for the GPS. If I use this tool it appends them, thereby doubling the length of time and halving my average speed. Is this the right tool for the job or should I be looking at another solution?

    S
  • Former Member
    0 Former Member over 10 years ago
    hi Janebee,

    Get yourself a free Dropbox account, upload the two files you want merged to it and then share the links in a reply message. I will see if I can merge them properly using the Fit File Repair Tool and get you a better outcome.

    cheers
    Mike