Click here to Skip to main content
15,881,836 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Dear All,
I want to know How to check video file or not Saving with HTTPPost when I get Request.file.
becoz if some user upload some photo ,I have to save that file.
for example
var file = Request.Files[0];
         file.SaveAs("The path I want to be save);


and then I get that file information from Microsoft.WindowsAPICodePackShell.
so I got the Video Duration from that file that I have been saved.
if i didn't get the Video Duration , I delete the file and return to user that is not support file.
Even I get the information from
C#
file.ContentType


but there are so many how can I ?
I don't want to check the contextType by constant?
for example application/mp4 or sth like.
I don't know how Youtube(Google) handle these things.
if there is anyone help me :-)

Best Regards,
Ko Ko Tun
Developer
B.A English
(+95) 973078722
Posted
Updated 21-Aug-14 0:36am
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900