本文整理汇总了C#中MenuEventArgs类的典型用法代码示例。如果您正苦于以下问题:C# MenuEventArgs类的具体用法?C# MenuEventArgs怎么用?C# MenuEventArgs使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
MenuEventArgs类属于命名空间,在下文中一共展示了MenuEventArgs类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: RulesMenu_MenuItemClick
protected void RulesMenu_MenuItemClick(object sender, MenuEventArgs e)
{
_mltView.ActiveViewIndex = Int32.Parse(e.Item.Value);
int i;
int index = _mltView.ActiveViewIndex;
//if(Session["insertSuccess"]!=null)
//RulesMultiView.ActiveViewIndex = (int)Session["insertSuccess"];
//Make the selected menu item reflect the correct imageurl
switch (index)
{
case 0:
RulesMenu.Items[0].ImageUrl = "~/Images/RSetup_over.gif";
deselectedMenu(0);
break;
case 1:
RulesMenu.Items[1].ImageUrl = "~/Images/AssignRules_over.gif";
deselectedMenu(1);
break;
case 2:
RulesMenu.Items[2].ImageUrl = "~/Images/EditRules_over.gif";
deselectedMenu(2);
break;
default:
RulesMenu.Items[0].ImageUrl = "~/Images/RSetup_over.gif";
deselectedMenu(0);
break;
}
}
示例2: NavigationMenu_MenuItemDataBound
protected void NavigationMenu_MenuItemDataBound(object sender, MenuEventArgs e)
{
bool IsShowMenu = false;
//var results = from am in sm.Access_Menu
// where am.Username == HttpContext.Current.User.Identity.Name
// select am;
//foreach (SecurityModel.Access_Menu item in results)
//{
// if (e.Item.ValuePath == item.MenuValuePath)
// {
// IsShowMenu = true;
// break;
// }
//}
foreach (string MenuValuePath in ShowMenu)
{
if (e.Item.ValuePath == MenuValuePath)
{
IsShowMenu = true;
break;
}
}
if (IsShowMenu == false)
{
if (e.Item.Parent != null)
{
e.Item.Parent.ChildItems.Remove(e.Item);
}
}
}
示例3: Menu1_MenuItemClick
protected void Menu1_MenuItemClick(object sender, MenuEventArgs e)
{
switch (e.Item.Value)
{
case "Inicio":
Response.Redirect("~/frmPrincipal.aspx");
break;
case "Inscripciones":
Response.Redirect("~/frmInscripciones.aspx");
break;
case "Permisos":
Response.Redirect("~/frmPermisos.aspx");
break;
case "Materias":
Response.Redirect("~/frmMaterias.aspx");
break;
case "Usuarios":
Response.Redirect("~/frmUsuarios.aspx");
break;
case "Personas":
Response.Redirect("~/frmPersonas.aspx");
break;
default:
break;
}
}
示例4: NavigationMenu_MenuItemClick
protected void NavigationMenu_MenuItemClick(object sender, MenuEventArgs e)
{
Session["Page_Name"] = e.Item.Text;
if (e.Item.Text.Equals ( "Tạo thẻ trả trước/Thẻ ghi nợ" ))
{
Response.Redirect("~/Secure/DebitPrepaid_Enter_Autho.aspx?type=Enter");
}
if( e.Item.Text.Equals ( "Duyệt thẻ trả trước" ))
{
Response.Redirect ( "~/Secure/DebitPrepaid_Enter_Autho.aspx?type=Authorize" );
}
if (e.Item.Text.Equals ( "Nạp tiền thẻ trả trước" ))
{
Response.Redirect("~/Secure/Balance_Prepaid.aspx?type=Enter");
}
if( e.Item.Text.Equals ( "Duyệt nạp tiền thẻ trả trước" ))
{
Response.Redirect ( "~/Secure/Balance_Prepaid.aspx?type=Authorize" );
}
// Alert.Show(sender.ToString()+"dat");
//Response.Redirect("");
// Response.Redirect("../Secure/PrepaidCard_update_Info_Request.aspx");
//Alert.Show(sender.ToString());
//if (sender.ToString() == "AuthorizeCredit")
//{
// Alert.Show("No priviliges");
//}
}
示例5: Menu1_MenuItemClick
protected void Menu1_MenuItemClick(object sender, MenuEventArgs e)
{
BuildGridSettings();
Menu itemClicked = (Menu)sender;
string path = Convert.ToString(itemClicked.SelectedItem.ValuePath);
//itemClicked.SelectedItem.Value is the Value of the menu item clicked, which set up as 1-7
string value = itemClicked.SelectedItem.Value;
querey = GetMenuItemClicked(value);
DisplayMenuClikedMessage(value);
//select statment baseed on the menu click
da = new SqlDataAdapter(querey, _conn);
da.Fill(ds);//Fill the DataSet from the DataAdapter
//Cache the DataSet for use later on in Pagging/Sorting
Cache["Data"] = ds;
gvBikeGrid.DataSource = ds;
gvBikeGrid.DataBind();
}
示例6: subMenuClick
//Controls for mnu_parking
protected void subMenuClick(object sender, MenuEventArgs e)
{
int index = Int32.Parse(e.Item.Value);
switch (index)
{
case 0:
ltv_parking.DataSource = objPark.getAllPermits();
DataBind();
_panelControl(pnl_list);
break;
case 1:
ltv_parking.DataSource = objPark.getCurrentPermits(DateTime.Now);
DataBind();
_panelControl(pnl_list);
break;
case 2:
ltv_parking.DataSource = objPark.getExpiredPermits(DateTime.Now);
DataBind();
_panelControl(pnl_list);
break;
case 3:
_panelControl(pnl_find);
break;
}
}
示例7: Menu1_MenuItemClick
protected void Menu1_MenuItemClick(object sender, MenuEventArgs e)
{
if (e.Item.Text == "")
{
}
}
示例8: ModulesMenu_MenuItemDataBound
protected void ModulesMenu_MenuItemDataBound(object sender, MenuEventArgs e)
{
SiteMapNode siteMapNode = (SiteMapNode)e.Item.DataItem;
string pathStringFormat = IsModuleActive(siteMapNode) ? ConfigurationManager.AppSettings["ModuleImagePathFormatString_Active"] : ConfigurationManager.AppSettings["ModuleImagePathFormatString_Inactive"];
e.Item.ImageUrl = String.Format(pathStringFormat, siteMapNode["imageName"]);
}
示例9: NavigationMenu_MenuItemClick
protected void NavigationMenu_MenuItemClick(object sender, MenuEventArgs e)
{
if (e.Item.Value == "Gestão de Cidades")
{
Session["PainelAct"]=1;
}
}
示例10: menuTabs_MenuItemClick
protected void menuTabs_MenuItemClick(object sender, MenuEventArgs e)
{
if(menuTabs.SelectedValue=="0")
{
}
emailtabs.ActiveViewIndex = Int32.Parse(menuTabs.SelectedValue);
}
示例11: SiteMenu_MenuItemClick
protected void SiteMenu_MenuItemClick(object sender, MenuEventArgs e)
{
Menu item = (Menu)sender;
Page.Response.Redirect(item.SelectedValue);
}
示例12: Menu1_MenuItemClick
protected void Menu1_MenuItemClick(object sender, MenuEventArgs e)
{
if (e.Item.Text == "Reminders")
Response.Redirect("./RemindersList.aspx");
else if (e.Item.Text == "Compose Mail")
Response.Redirect("./SendMail.aspx");
else if (e.Item.Text == "Compose Message")
Response.Redirect("./SendMessage.aspx");
}
示例13: ActionsMenu_MenuItemDataBound
protected void ActionsMenu_MenuItemDataBound(object sender, MenuEventArgs e)
{
SiteMapNode siteMapNode = (SiteMapNode)e.Item.DataItem;
SiteMapNode moduleNode = GetModuleNode();
if (moduleNode != null && IsNodeActive(siteMapNode))
{
e.Item.ImageUrl = String.Format(ConfigurationManager.AppSettings["ModuleImagePathFormatString_Action"], GetModuleNode()["imageName"]);
}
}
示例14: mnu_cerrartodo_MenuItemClick
protected void mnu_cerrartodo_MenuItemClick(object sender, MenuEventArgs e)
{
if (mnu_cerrartodo.SelectedItem.Value == "Logout")
{
Session.Abandon();
Response.Cookies.Add(new HttpCookie("ASP.NET_SessionId", ""));
//Response.Redirect("~/login01.aspx");
Response.Redirect("~/login.aspx");
}
}
示例15: PartsMenu_MenuItemClick
protected void PartsMenu_MenuItemClick(object sender, MenuEventArgs e)
{
foreach (WebPartDisplayMode mode in MyPartManager.DisplayModes)
{
if (mode.Name.Equals(e.Item.Text))
{
MyPartManager.DisplayMode = mode;
}
}
}