 |
|
 |
Hi Shyam,
really loved your work on that file upload, Brilliant. I'm fairly new to ASP.NET. When i am using AJAX ScriptManager control which contains 2 dropdown list (changing value on the 1st drop down will change the list on the 2nd drop down) on my front page in conjunction with your script, everytime when i choose a value from the 1st drop down list, which involves a postback, and its trying to upload the image again. and if i clear the control value, the uploading image just remains there forever. How can i resolve this issue? Your help would be greatly appreciated. Thanks again for the great tool you have done.
Jack
|
|
|
|
 |
|
 |
Hi Jack,
Thank you for your interest. I haven't checked your problem but I have interested a new falsh/javascript option for uploading file. You can find it at http://swfupload.org/[^]. It is a free tool and you can use it.
Best Regards,
Shyam S
|
|
|
|
 |
|
 |
Gmail is using flash for uploading file. A free flash tool is available known as 'SWFUpload' which can be used to upload file like gmail manner.
|
|
|
|
 |
|
 |
Hello,
When I am working in master page its not working. A run time error has occurred, Object is required in function.
function startCallback()
{
document.getElementById("processDiv").style.display = "block";
document.getElementById("fileName").innerText = document.getElementById("FileUpload1").value;
return true;
}
Thanks,
Sabarish
|
|
|
|
 |
|
 |
Hi All,
I have tried this file upload control it is working fine without any validations. But When I have added required field validators,regular expression validators,custom validators and validation summary in the form It's behavior is strange. As I click on submit button it is calling startCallback function so I have checked innerHTNL length of validation summary. If length =0 I am displaying progress bar.So after that it was working fine but When I click on logout button of master page validation summary length is =0 so It is displaying progress bar. So how can I handle this error as I dont want to show progress bar at that time. the problem is like when form is submitted at that time startCallback is called so can I do some change in control so I can know that which button is clicked at client side or please provide me any other solution.
Please reply me as soon as possible.
Thanks,
Kaivan Shah
|
|
|
|
 |
|
 |
Greetings Shyam,
Thank you very much for this article. i had small question regarding this upload button, can we use this upload button in the edit template of the gridview .
Regards,
Jaipal
|
|
|
|
 |
|
 |
Nice article. It works great.
But what if I add another button to the page, which submits the main page? The form is then submitted into the IFRAME, which is not correct. Do you have a solution for this?
Thx,
Dennieku
|
|
|
|
 |
|
 |
Sorry, I see that the post with subject "Problem with postback" handles the same problem.
I'll try to find a solution !!
|
|
|
|
 |
|
 |
Hi,
it might sound as a dumb question, but heck -
* where is the file?! *
I see the upload, but I don't know where was the file saved and how to set the location.
did I miss something very basic here?
Thanks,
- Arnon.
|
|
|
|
 |
|
 |
Even i couldn't see the uploaded file, anywhere, in my virtual directory
How ???
|
|
|
|
 |
|
 |
Hi, thx for your article, it's great, but I have a problem and would like to see if someone can help me.
If I put the control in a page with other buttons that can do a submit, with any button I press, the last image gets uploaded again to the server.
I saw that the FileUpload control clears itself with a page postback, but that's not happening with postbacks in the sample.
Can someone help me with this?
Thanks in advance.
|
|
|
|
 |
|
 |
Hi,
Thank you for your feedback. The problem is, the control registers an onsubmit statement. When page submits, by any button in that form, this code will be executed. Also the sample application will not clear the file upload control. As a quick solution, if we cear the file upload control after post back, by javascript, u can solve this problem. You can do it in completeCallback javascript function.
If this will not work in your situation, please let me know with detailed explanation of ur situation. We can make it possible
Regards,
Shyam S
|
|
|
|
 |
|
 |
Hi,
How to clear the file upload control value, after the file uploaded to the server .(need JavaScript code).
Thanks
Sabarish
|
|
|
|
 |
|
 |
Hi shyam,
Your control works like charm and kudos for creating it. Now i had a requirement where i need to add the the file upload control dynamically. for that the form need to have enctype="multipart/form-data" . How can this be achieved in ur control?
|
|
|
|
 |
|
 |
Hi ShyamProxy,
Can I use your control to surpas the upload limit that I would normally see when using upload controls?
Is this Ajax upload button for DoTNet2 by the way and when is the Java edition coming out? I think we can really use it!!
Cheers,
RichardOfMercator
|
|
|
|
 |
|
 |
Hi,
Can I have the test project as well. cause I don't know how to retrieve the file and save to the server hard disk
Thank
Yong
|
|
|
|
 |
|
 |
I placed your code into ajax UpdatePanel, and i retrieve 'AN exception occurred' exception.
I debugged it and saw that related FileUpload control doesn't have PostedFile.
|
|
|
|
 |
|
 |
Hi dkc_project,
Thanks for your feedback.
According to 'liammclennan', 'FileUpload control does not work with asynchronous postbacks, and therefore does not work from within an AJAX UpdatePanel.'. Please go to this link 'http://www.codeproject.com/useritems/simpleajaxupload.asp' for a solution. I haven't tested this control in update panel.
Thank you
Shyam
|
|
|
|
 |
|
 |
Yes, standard FileUpload control does not work within AJAX UpdatePanel.
If you want to upload file asynchronously within AJAX UpdatePanel, try AsyncFileUpload from http://www.arindsoft.com.
|
|
|
|
 |
|
 |
This is a nice article...
|
|
|
|
 |