This is a migrated thread and some comments may be shown as answers.

a bug about contentMenu

1 Answer 11 Views
Menu
This is a migrated thread and some comments may be shown as answers.
C
Top achievements
Rank 1
C asked on 16 Sep 2013, 01:28 PM

 

RadWindowManager2.RadConfirm("Server radconfirm: Are you sure?", null, 330, 180, null, "Server RadConfirm", null);it didn't work with "contentMenu"
protected void RadMenu1_ItemClick(object sender, RadMenuEventArgs e)
        {
            int radGridClickedRowIndex;
            radGridClickedRowIndex = Convert.ToInt32(Request.Form["radGridClickedRowIndex"]);
            switch (e.Item.Text)
            {
 
                 
                case "Delete":
                    RadWindowManager2.RadConfirm("Server radconfirm: Are you sure?", null, 330, 180, null, "Server RadConfirm", null);
                    SqlConnection con3 = AllClass.dbConnection();
                    string sd = "delete from tbPlan where PlanID=" + this.RadGrid2.MasterTableView.DataKeyValues[radGridClickedRowIndex]["PlanID"] + "";
                    AllClass.saveData(sd,con3);
                    show(this.RadDataPager1.CurrentPageIndex);
                    getcnt();
                    break;
 
            }
        }

1 Answer, 1 is accepted

Sort by
0
Shinu
Top achievements
Rank 1
answered on 03 Oct 2013, 09:52 AM
Hi C,

Please have a look into the full code  that I tried.

ASPX:
<telerik:RadMenu ID="RadMenu1" runat="server" OnItemClick="RadMenu1_ItemClick">
    <Items>
        <telerik:RadMenuItem Text="Item1" runat="server">
            <Items>
                <telerik:RadMenuItem Text="Item1.1" runat="server">
                </telerik:RadMenuItem>
            </Items>
        </telerik:RadMenuItem>
        <telerik:RadMenuItem Text="Item2" runat="server">
        </telerik:RadMenuItem>
        <telerik:RadMenuItem Text="Item3" runat="server">
        </telerik:RadMenuItem>
    </Items>
</telerik:RadMenu>

C#:
protected void RadMenu1_ItemClick(object sender, Telerik.Web.UI.RadMenuEventArgs e)
{
    switch (e.Item.Text)
    {
        case "Item1": RadWindowManager1.RadConfirm("Item1", null, 300, 300, null, "Item1");
            break;
        case "Item2": RadWindowManager1.RadConfirm("Item2", null, 300, 300, null, "Item2");
            break;
        case "Item3": RadWindowManager1.RadConfirm("Item3", null, 300, 300, null, "Item3");
            break;
        default: RadWindowManager1.RadConfirm(e.Item.Text, null, 300, 300, null, "Items");
            break;
    }
}

Please elaborate your requirement if it doesn't help you.
Thanks,
Shinu.
Tags
Menu
Asked by
C
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 1
Share this question
or