Hi,
I am uploading a video file, i want to convert its extension from .mp4 to .avi without changing the other properties of the uploaded file.
Loading
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Eli BangzPosted May 28, 2015, 3:37 AM
If you mean that you want to convert the MP4 video file to AVI file format before uploading it, you can achieve this using DirectShow, but it will be complicated if you are not familiar with DirectShow programming.
It will be easier if you use a higher-level programming toolkit like leadtools. the following link shows how to convert videos from AVI to MP4, and I think you can change it to do what you need:
http://support.leadtools.com/SupportPortal/CS/forums/35394/showpost.aspx
But if you mean that you want to change only the extension of the file from .MP4 or .AVI without changing the actual file data, you can use the File.Move with the Path.ChangeExtension methods as follows:
File.Move(myffile, Path.ChangeExtension(myffile, ".AVI"));