Avoiding postback on upload control when another button is clicked

S

SBK

Hi All,

Got a quick problem, hoping someone can help me out here.

Using an Upload Control. If a file to upload is specified and another form
action is committed (i.e. btnBack) then the upload control will still post
the file but not call the event.

Anything I can do to prevent this?


Thanks in advance.
 
B

bruce barker

as the value can be cleared, in client script disable the upload control
via the onclick event of the buttons you don't want to post the file.
the browser will not post disabled fields.

-- bruce (sqlwork.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

Forum statistics

Threads
473,755
Messages
2,569,537
Members
45,020
Latest member
GenesisGai

Latest Threads

Top