HttpPostedFileBase status in asp.net mvc

WebStYler

New Member
An asp.net mvc action takes an HttpPostedFileBase parameter:\[code\]public ActionResult Save(HttpPostedFileBase file){ //Q1: at the start of this action method, what's the status of this file? //UploadCompleted or Uploading or something else? //Q2: where is the file stored? memory or a temp file? if (answer of Q1 is Uploading) { //Q3: what happens if file.SaveAs is invoked? //block the current thread until the file is uploaded? }}\[/code\]Q4 here: I want to record the total time of this request, when the user begins to upload the file, the timer starts.when the user finished uploading the file(or my \[code\]Save\[/code\] action is completed), the timer ends. How can I know when the user begins to upload?
 
Back
Top