c# - ImageButton in UpdatePanel doesn't PostBack -


I have created a form in a popup window, in which it is UpdatePanel with ImageButtons.

Initially, I used to test linkbutons, but I need image buttons. The thing is, it works well with linkbutton and the image is not with buttons (absolutely nothing happens).

Checking the source, I think the Javascript call is slightly different:
link button:

; a href = "javascript: WebForm_DoPostBackWithOptions (New WebForm_PostBackOptions (& amp; quot; ctl00 $ CPHC $ ctrlAdr $ AdrMapo $ lbAdresseSaisie & amp; quot;, & amp; quot; & amp; quot;, true, & amp; quot; & amp; quot;, & amp; quot; & amp; quot,;, false true)) "id =" ctl00_cphC_ctrlAdr_AdrMapo_lbAdresseSaisie "& gt; Trial & lt; / A & gt;  

ImageButton:

  & lt; Input align = "absmiddle" type = "image" style = "border-width: 0px;" Onclick = "javascript: WebForm_DoPostBackWithOptions (New WebForm_PostBackOptions (& amp; quot; ctl00 $ cphc $ ctrlAdr $ AdrMapo $ rpAdressesProposees $ ctl00 $ ibAdresseProposee & Amp; quot ;, & amp; quot; and & quot; true, & quot; & amp; quot ;, & amp; amp; quot ;, & quot; false, false)) "... & gt; ; After  

Check out the document, I think that called WebForm_PostBackOptions last parameter clientSubmit and set it , Then a true is submitted to one. This value for the ImageButton is set to false and if I do it true manually do changes with Fayrbg, if it works as expected but whenever control ready If so, then I can not find any way to change that parameter. And I am quite upset

If i ImageButton.CausesValidation is set, there is no generated JavaScript and when I click on the button then nothing happens UpdatePanel This is declared as:

   

And to ensure that I declare a trigger for ImageButton. I use UpdateMode = "conditional" because it needs to be updating updating updatesPanel events from programmingly.

LinkButton correctly presented in the same situation, so I do not know what I have done wrong ...

Is there a client-side validation that is blocking postbacks? Do you do a postback, if you remove the update panel from the page? I do the tests so that you can determine whether this is a problem with UpdatePanel + ImageButton or just Imagebutton.


Comments

Popular posts from this blog

Eclipse CDT variable colors in editor -

AJAX doesn't send POST query -

wpf - Custom Message Box Advice -