Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

HttpPostedFileBase.SaveAs method question

Tags:

I've got an asp.net mvc application that uploads a file and stores them in one of the directories where the website is located.

My question is... When you execute HttpPostedFileBase.SaveAs() method saving it with the same name as an existing filename on the folder, does HttpPostedfileBase overwrite the file?

Thanks a million!

like image 343
mallows98 Avatar asked Feb 18 '10 22:02

mallows98


1 Answers

Yes. Any existing file will be overwritten. (I checked the source)

like image 149
SLaks Avatar answered Nov 26 '22 08:11

SLaks