I am having trouble getting a ModalPopupExtender to display with the corresponding data. This will be triggered by clicking on a "Details" button in a gridview. Eg. by clicking on Row1 details button, ModalPopup will display Row1 information
I suspect this might be due to the following section:
Expand|Select|Wrap|Line Numbers
- protected void grdBookings_RowDataBound(object sender, GridViewRowEventArgs e)
- {
- if (e.Row.RowType == DataControlRowType.DataRow)
- {
- Button Details1 = (Button)e.Row.FindControl("details1");
- Details1.Attributes.Add("onclick", "return ShowMyModalPopup('" + grdBookings.DataKeys[e.Row.RowIndex].Values + "')");
- }
- }
Expand|Select|Wrap|Line Numbers
- <asp:ModalPopupExtender ID="ModalPopupExtender1" BehaviorID="ModalPopupExtender1Behaviour" runat="server"
- PopupControlID="Panel1" TargetControlID="details1" BackgroundCssClass="modalBackground"
- OnCancelScript="HideModalPopup()" CancelControlID="Close"></asp:ModalPopupExtender>
I hope those in the know could help me as much as possible, thank you.