fileupload fails in updatepanel

J

Jeremy

I have a fileupload component and a submit button inside an updatepanel.
(C#, asp2). In the debugger in page load, I see that the hasfile property
is false, even though the fileupload control was used to select an existing
file on the client.

If I move the 2 controls outside the updatepanel then hasfile is true in
page load.

How to workaround this?

Jeremy
 
S

Shamus

Following up .. On the asp.net ajax site, in the overview page,

http://www.asp.net/ajax/documentation/live/overview/UpdatePanelOvervi...

I find the following

"To use a FileUpload control inside an UpdatePanel control, set the postback
control that submits the file to be a PostBackTrigger control for the
panel."

However, this does not work. IOW, adding the submit button's onclick event
as a trigger does not change anything.

Jeremy

Post your code...
 
P

PJ on Development

I have a fileupload component and a submit button inside an updatepanel.
(C#, asp2). In the debugger in page load, I see that the hasfile property
is false, even though the fileupload control was used to select an existing
file on the client.

If I move the 2 controls outside the updatepanel then hasfile is true in
page load.

How to workaround this?

Jeremy

Jeremy,

The UpdatePanel control is incompatible with the FileUpload control.
Period.

I have a simple control at http://pjondevelopment.50webs.com/articles/asyncupload.html
that people are using to circunvent this problem.

Take a look.

Regards,

Paulo Santos.
http://pjondevelopment.50webs.com
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,969
Messages
2,570,161
Members
46,705
Latest member
Stefkari24

Latest Threads

Top