HighTechTalks DotNet Forums  

fileupload fails in updatepanel

ASP.net Web Controls microsoft.public.dotnet.framework.aspnet.webcontrols


Discuss fileupload fails in updatepanel in the ASP.net Web Controls forum.



Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old   
Jeremy
 
Posts: n/a

Default fileupload fails in updatepanel - 12-12-2007 , 02:58 PM






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


Reply With Quote
  #2  
Old   
Jeremy
 
Posts: n/a

Default Re: fileupload fails in updatepanel - 12-12-2007 , 04:58 PM






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

http://www.asp.net/ajax/documentatio...lOverview.aspx

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



"Jeremy" <jeremy-nospam (AT) ninprodata (DOT) com> wrote

Quote:
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


Reply With Quote
  #3  
Old   
Shamus
 
Posts: n/a

Default Re: fileupload fails in updatepanel - 12-16-2007 , 07:55 AM



On Dec 13, 12:58 am, "Jeremy" <jeremy-nos... (AT) ninprodata (DOT) com> wrote:
Quote:
Following up .. On the asp.net ajax site, in the overview page,

http://www.asp.net/ajax/documentatio...atePanelOvervi...

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

"Jeremy" <jeremy-nos... (AT) ninprodata (DOT) com> wrote in message

news:u8etIHQPIHA.292 (AT) TK2MSFTNGP02 (DOT) phx.gbl...

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
Post your code...


Reply With Quote
  #4  
Old   
PJ on Development
 
Posts: n/a

Default Re: fileupload fails in updatepanel - 12-17-2007 , 08:35 AM



On Dec 12, 6:58 pm, "Jeremy" <jeremy-nos... (AT) ninprodata (DOT) com> wrote:
Quote:
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/ar...yncupload.html
that people are using to circunvent this problem.

Take a look.

Regards,

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


Reply With Quote
Reply




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.