|
CopyTo method fails with large files
Last post 12-15-2009, 9:14 PM by cutechat. 16 replies.
-
11-24-2009, 7:32 PM |
-
Abosho
-
-
-
Joined on 10-30-2009
-
-
Posts 12
-
-
|
CopyTo method fails with large files
Hi,
I'm uploading a 450MB file. The file uploads well into de temp directory. But when calling this method args.CopyTo("~/Downloads/" + args.FileName);
with in Uploader_FileUploaded event I receive de folowing error message
"Unable to find library '/AjaxCallObject.js'. Copy the file to the required location, or change the 'scriptPath' setting at magicAjax section web.config"
I only have this error when upload large files, the same code works very well with small files, ex: 4MB
Note:
- The application is running into a shared hosting. May it has to do with RAM memory limit?
- Is it possible to prevent the deletion of the files in Temp folder after they are uploaded?
Thanks,
Ariel
|
|
-
11-24-2009, 8:51 PM |
-
cutechat
-
-
-
Joined on 07-22-2004
-
-
Posts 2,332
-
-
|
Re: CopyTo method fails with large files
Ariel,
If you remove the CopyTo line , and upload the 450MB file again , will you get such error again ?
Regards, Terry
|
|
-
11-25-2009, 6:36 AM |
-
Abosho
-
-
-
Joined on 10-30-2009
-
-
Posts 12
-
-
|
Re: CopyTo method fails with large files
I get te error with the CopyTo method, if i remove this line i dont have the error.
Its ocurrs only with large files.
what can i do?
Thanks
Ariel
|
|
-
11-25-2009, 6:43 AM |
-
cutechat
-
-
-
Joined on 07-22-2004
-
-
Posts 2,332
-
-
|
Re: CopyTo method fails with large files
Ariel
CopyTo may take a long time and the ASP.NET page will timeout.
Please try MoveTo , or set the Server.ScriptTimeout to a larger value.
Regards, Terry
|
|
-
11-25-2009, 7:00 AM |
-
Abosho
-
-
-
Joined on 10-30-2009
-
-
Posts 12
-
-
|
Re: CopyTo method fails with large files
Is it possible to prevent the deletion of the files in Temp folder after they are uploaded? if possible, it is not necessary to execute an extra operation such as copyTo or MoveTo
Thanks,
Ariel
|
|
-
11-25-2009, 2:58 PM |
-
Abosho
-
-
-
Joined on 10-30-2009
-
-
Posts 12
-
-
|
Re: CopyTo method fails with large files
cutechat:
Ariel
CopyTo may take a long time and the ASP.NET page will timeout.
Please try MoveTo , or set the Server.ScriptTimeout to a larger value.
Regards, Terry
Terry,
I tried using the MoveTo method and recieved the same error.
Then I changed the Server.ScriptTimeout to a larger value and got no error, but the file had not been moved.
What about avoiding the temp folder to be deleted. Is it possible?
Thanks,
Ariel
|
|
-
11-26-2009, 10:09 AM |
-
11-26-2009, 10:30 PM |
-
cutechat
-
-
-
Joined on 07-22-2004
-
-
Posts 2,332
-
-
|
Re: CopyTo method fails with large files
Ariel,
You can try/catch the CopyTo/MoveTo to check whether it's throw error.
Regards, Terry
|
|
-
12-01-2009, 5:18 PM |
-
Abosho
-
-
-
Joined on 10-30-2009
-
-
Posts 12
-
-
|
Re: CopyTo method fails with large files
Terry, Heres is the capture of my screen widht the error. Im using MoveTo .... The error took place only with large file for ex 400MB Tanks, Ariel
|
|
-
12-02-2009, 6:59 AM |
-
cutechat
-
-
-
Joined on 07-22-2004
-
-
Posts 2,332
-
-
|
Re: CopyTo method fails with large files
Ariel,
That is a strange error.
Can you determine which mode you are using ?
IFrame ? Flash ? Sliverlight ?
If your IE does not install Flash/Silverlight , uploader will use IFrame mode, and then you can't select multiple files in the dialog.
I think that maybe a bug of IFrame mode.
Regards, Terry
|
|
-
12-02-2009, 8:23 PM |
-
Abosho
-
-
-
Joined on 10-30-2009
-
-
Posts 12
-
-
|
Re: CopyTo method fails with large files
Terry,
I solve the error, I put in the pages <%@ Page Language="C#" EnableViewStateMac="false"%> and it works fine.
But now I have another error. The file upload into the temp directory but it has the name uploadingXXXXX.resx ... and it not was copy... and the name does not change to persisted.XXXXX.resx
Here are the screens, first the screen with the error. And second is a capture of the FTP, so you can see the name of the file
|
|
-
12-03-2009, 12:43 AM |
-
cutechat
-
-
-
Joined on 07-22-2004
-
-
Posts 2,332
-
-
|
Re: CopyTo method fails with large files
Hi,
This error often throws when the server side uploader control can't intercept the Ajax validating request.
Do you get such error only when upload large files ?
Do you add the uploader into the page dynamically ?
Regards, Terry
|
|
-
12-03-2009, 12:46 AM |
-
cutechat
-
-
-
Joined on 07-22-2004
-
-
Posts 2,332
-
-
|
Re: CopyTo method fails with large files
It seems that error relative to the ViewStateMac error.
You disable the ViewStateMac , but get another error , because the posted content is wrong ,
I think that is a bug of uploader while processing your big file .
Please try the last version , we did update that issue for the big ViewState case.
Regards, Terry
|
|
-
12-03-2009, 10:47 AM |
-
Abosho
-
-
-
Joined on 10-30-2009
-
-
Posts 12
-
-
|
Re: CopyTo method fails with large files
Terry,
The error only appear with large files.
Thanks,
Ariel
|
|
-
12-03-2009, 12:53 PM |
-
12-15-2009, 11:29 AM |
-
Abosho
-
-
-
Joined on 10-30-2009
-
-
Posts 12
-
-
|
Re: CopyTo method fails with large files
I am experimenting the following problem: Once I upload the file I try to copy it to another folder. Some times the whole upload-copy process freezes on 100%, and later on, recieve a messege indicating that the file does not exists.
I am suposing that the file is being deleted from the temp folder before it complets the copy operation. So...how does the temp folder cleanup works? - Does it delete all the "uploaded---*****" files every an amount of time? In that case, I am exposed to that behavior randomly - Does it delete each "uploaded---*****" file X time after it has been created? In that case, how much time after? I would not understand why the copy operation cannot be completed before it is cleaned up.
Could the uploader that persists the files more time in the temp folder helps?
Thanks,
Ariel
|
|
-
12-15-2009, 9:14 PM |
-
cutechat
-
-
-
Joined on 07-22-2004
-
-
Posts 2,332
-
-
|
Re: CopyTo method fails with large files
Ariel,
The files will be deleted , if their modified-time pass for 6 hours.
Regards, Terry
|
|
|
|
|