Hi,
I am new in dotnetnuke module development.
Settings: dotnetnuke 7 + christoc , telerik ajax ui conrols: Q2 release 2. I have registered a usercontrol Patientupdate.ascx in DNN and inside it I have a radwindow and inside the radwinodw another (normal)usercontrol COVUserControl. The radwindow is called inside a radgrid in formedit mode.
a snippet of the code for the radwindwo (inside the patientupdate.ascx)
<telerik:RadWindow ID="COVWindow" Title="Editing record" Width="270"
Height="540" VisibleOnPageLoad="false" Behaviors="Resize, Minimize, Close, Pin, Maximize, Move"
Left="610" EnableShadow="true" runat="server" OnClientClose="refreshGrid" Modal="true">
<ContentTemplate>
<asp:Panel ID="Panel1" runat="server">
<COVUC:COVUserControl runat="server" ID="COVUCID"/>
</asp:Panel>
</ContentTemplate>
</telerik:RadWindow>
In the edit template I have a button named <COV check> and in the ResuiltaatGrid_Itemcommand I have the following code:
protected void ResultaatGrid_ItemCommand(object sender, GridCommandEventArgs e)
{
if (e.CommandName == "COV")
{
GridEditableItem editedItem = e.Item as GridEditableItem;
string pCperID = editedItem.GetDataKeyValue("cpersoon_id").ToString();
COVWindow.Width = 500;
COVWindow.Height = 250;
COVUserControl COVUC1 = COVWindow.ContentContainer.FindControl("COVUCID") as COVUserControl;
COVUC1.cPersoonID = pCperID;
RadGrid COVGrid = COVUC1.FindControl("COVGrid") as RadGrid;
string script = "function f(){$find(\"" + COVWindow.ClientID + "\").show(); Sys.Application.remove_load(f);}Sys.Application.add_load(f);";
ScriptManager.RegisterStartupScript(this, this.GetType(), "key", script, true);
COVGrid.Rebind();
}
}
The problem is that the radwindow does not pop-up. (I have check the pop-up in host -> extension-> and check allow pop-ups for the module).
The same code works when NOT a dotnetnuke module. (just plain patientupdate.aspx).
I think that the code lines does not fire:
string script = "function f(){$find(\"" + COVWindow.ClientID +
"\").show();
Sys.Application.remove_load(f);}Sys.Application.add_load(f);";
ScriptManager.RegisterStartupScript(this, this.GetType(), "key", script, true);
If I asked Telrerik then they say that its is dotnetnuke problem....
Thanks in advance.
Regards,
Ton