MaxSizeKB Confusing Error Message

  •  10-25-2012, 11:56 AM

    MaxSizeKB Confusing Error Message

    Hoping I'm just missing something here.  I'm basically using the mvc_cs Large_File_Upload action as my base. Building my MvcUploader like this

     

                 var uploader = new MvcUploader(System.Web.HttpContext.Current)
                                   {
                                       UploadUrl = Response.ApplyAppPathModifier("~/UploadHandler.ashx"),
                                       Name = "upload",
                                       AllowedFileExtensions = AllowedExtensions,
                                       InsertText = "Select a file to upload",
                                       MaxSizeKB = 20000000
                                   };

     

    Getting an error message when uploading larger files

     "30 EXHBIT FABRICATION_120727.zip cannot be uploaded!

    File size (435 MB) is too large. The maximum file size allowed is set to: 19.1 GB"

     

    First, that error makes no sense, 435 MB is far less than 19.1 GB! Unless my math is wrong.

     

    Second, this error displays *after* the entire upload has taken place. That seems counter-productive, the error should display before the upload occurs.

    What am I doing wrong?

View Complete Thread