Rank: Advanced Member
Joined: 6/10/2011 Posts: 37 Points: 111 Location: Belgrade
|
Hi,
I use EntreeFileInput control and I need to save file that I am selected to file system folder. In basic asp.net control FileInput there is an method SaveAs() that allow that. Is it possible to do that with EntreeFileInput because I pass the string to my web service that reference to file system path.
Thanks,
Alex
|
 Rank: ME Staff
Joined: 1/12/2009 Posts: 279 Points: 408 Location: VA
|
First, you need to be sure your clickaction has ForcePostback = true. This will make the request use a postback instead of AJAX, and will include the file that was selected.
Second, you access the posted file via the EntreeScope.FormFiles like this:
System.Web.HttpPostedFile file = EntreeScope.FormFiles[0]; file.SaveAs("yourfilename");
You will need to add a reference to System.Web in your project to be able to use the HttpPostedFile class.
|
Rank: Advanced Member
Joined: 6/10/2011 Posts: 37 Points: 111 Location: Belgrade
|
Awesome!
Thanks
|