Click here to Skip to main content
15,908,776 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hey i am developing a web application that saves videos in folders for them to be streamed later on. i am using asp.net c# and have been struggling with uploading ans saving video files in a folder to access them using html5 or embedding a flash player.

could you please help me with this?

i am currently using a file upload control and a button
this is the code for the button
FileUpload1.SaveAs(Server.MapPath("/blablabla/" + FileUpload1.FileName));

but it does not save my video in the folder.

also,

is there a way i can store the location of the video files as string in the .mdf database ?

can you please help me with some code?

please help

thanks

sarah
Posted
Comments
idenizeni 1-Aug-13 17:26pm    
As for the file save issue; you need to ensure the credentials the web application is running under has write permissions to the file save directory.
TryAndSucceed 1-Aug-13 17:37pm    
Above Comment + also check if your path is correct.

1 solution

Hi.. dear,

Try this

C#
string filename = Path.GetFileName(FileUpload1.FileName);
FileUploadControl.SaveAs(Server.MapPath("~/") + filename);
 
Share this answer
 

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