Hi,
I want to open a radWindow when i click the "Add New Row" Button. I know, i could use a Hyperlink (custom commanditem) - this would be an option if i could use the default style of the Insert Button.
I already stopped the default Insert Event with this code.
In the ItemCreaded Event I tried to add a "onclick" event, but this wont work.
This is my javascript function.
And this is my radWindowManager
I dont have another idea, how i can solve this - i really want to keep the default style of the commanditem - it looks really great.
Best regards,
Raimund
I want to open a radWindow when i click the "Add New Row" Button. I know, i could use a Hyperlink (custom commanditem) - this would be an option if i could use the default style of the Insert Button.
I already stopped the default Insert Event with this code.
protected void gvUser_ItemCommand(object sender, GridCommandEventArgs e){ if (e.CommandName == RadGrid.InitInsertCommandName) { e.Canceled = true;
... some code ... }}In the ItemCreaded Event I tried to add a "onclick" event, but this wont work.
protected void gvUser_ItemCreated(object sender, Telerik.Web.UI.GridItemEventArgs e) { if (e.Item is GridCommandItem) { LinkButton addButton = e.Item.FindControl("InitInsertButton") as LinkButton; addButton.Attributes["onclick"] = "return ShowInsertForm();"; } }This is my javascript function.
function ShowInsertForm() { window.radopen("Bearbeiten.aspx?umleitung=-1", "rwBearbeiten"); return false;}And this is my radWindowManager
<telerik:RadWindowManager ID="rwmBearbeiten" runat="server" EnableShadow="true"> <Windows> <telerik:RadWindow ID="rwBearbeiten" runat="server" ShowContentDuringLoad="false" Width="800px" Height="650px" Title="Bearbeite Umleitungsdaten" Behaviors="Default" Modal="true" ReloadOnShow="true"> </telerik:RadWindow> </Windows></telerik:RadWindowManager>I dont have another idea, how i can solve this - i really want to keep the default style of the commanditem - it looks really great.
Best regards,
Raimund