Monday, March 26, 2012

Modal PopUp problem

Hi guys, my name is steven.i have a problem with modalpopupextender.

i have a linkbutton as the targetcontrolid.

the modalpopupextender runs perfectly as i click the linkbutton, but the code inside linkbutton_click was not executed.

my question is how can i execute the code inside linkbutton_click?

thanx for the sharing.

That is because the ModalPopup prevents the default event so no other handlers will be called. If you would like code to execute before or after the modalpopup window is shown you can hook into the 'showing' or 'shown' events. Here is alink to a postthat shows how to do that.

_onShow :function(e) {

/// <summary>

/// Handler for the target's click event/// </summary>/// <param name="e" type="Sys.UI.DomEvent">/// Event info/// </param>if (!this.get_element().disabled) {this.show();

e.preventDefault();

returnfalse;

}

},


mmm i kinda confuse...

here what i want to do, i have a linkbutton as the targetcontrolid from modalpopupextender.

the popupcontrolid is panel1. inside panel1 there is a detailsview in readonly mode.

when i click the linkbutton i want the popup show and the detailsview is in insert mode.

can you tell me how?

thanx so much.

No comments:

Post a Comment