Hi,
I'm using the AsyncUpload control in an MVC.NET project, and want to change the TempTargetFolder (dynamically) in the IAsyncUploadResult method. However, I don't have access to Session variables for the current context. (Either accessed via Session. or context parameter)
Here's an example of my code:
Any suggestions?
Thanks!
Pete
I'm using the AsyncUpload control in an MVC.NET project, and want to change the TempTargetFolder (dynamically) in the IAsyncUploadResult method. However, I don't have access to Session variables for the current context. (Either accessed via Session. or context parameter)
Here's an example of my code:
protected override IAsyncUploadResult Process(UploadedFile file, HttpContext context, IAsyncUploadConfiguration configuration, string tempFileName){ // This will throw an exception even when I've set it in the controller configuration.TempTargetFolder = context.Session["MySessionVar"].ToString(); return base.Process(file, context, configuration, fileName);}Any suggestions?
Thanks!
Pete