How to replace audio tracks in avi file?

I have two divx/ xvid encoded avi files of the same movie. One has video screwed up and the other has audio screwed up. I want to cut out audio track from one file and put it in the other.

Anyone know how to do that or any software capable of it. Thanks.

there is a software called vcd cutter which can be use to split audio and video files, and then yon put another audio file and join them. but are you sure that both video files have same frame rate.

file with bad video is 29 fps - its where i want to get the (5.1) audio track from. file with good video is 23 fps and thats where i want to put the new audio track.

Since length of both video files is EXACTLY the same i shoudn't have any problems right?

orite mate...solved the problem. used virtualdub to stream out the ac3 track and then put it in the new avi file. works a charm now. Thanks anyways.