菜单控制

编程入门 行业动态 更新时间:2024-10-25 12:24:31
本文介绍了菜单控制 - 当前节点的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

在母版页上使用新的ASP.NET 2.0菜单控件。 有没有办法让当前页面成为实时链接,理想情况下也是b $ b b让它以不同的风格出现? 类似于sitemappath控件'的RenderCurrentNodeAsLink属性。 TIA - AG 电子邮件:讨论在adhdata dot com

解决方案

" AG" < NO ********** @ newsgroups.nospamwrote in message news:%2 **************** @ TK2MSFTNGP02。 phx.gbl ...

在母版页上使用新的ASP.NET 2.0菜单控件。 有没有办法不让当前页面成为实时链接,理想情况下,也会以不同的风格出现? 类似于sitemappath控件的RenderCurrentNodeAsLink属性。

我认为只有使用< asp:Menu>属性才能实现。 代码死了很容易,但是......

小心提示? - AG 电子邮件:讨论在adhdata dot com " Mark Rae" < ma ** @ markNOSPAMrae写信息 news:en ************** @ TK2MSFTNGP03.phx.gbl ... " AG" < NO ********** @ newsgroups.nospamwrote in message news:%2 **************** @ TK2MSFTNGP02。 phx.gbl ...

>在母版页上使用新的ASP.NET 2.0菜单控件。有没有办法没有当前页面是一个实时链接,理想情况下它也会以不同的样式出现? 类似于sitemappath控件的RenderCurrentNodeAsLink属性。

我不认为只有< asp:Menu>的属性才能实现。 代码死了很容易,但是......

你好AG, 如果你在Menu控件上使用DataBinding,你可以处理它的'b DataBound事件并更改当前项: protected void Menu1_DataBound(object sender ,EventArgs e) { if(Menu1.SelectedItem.NavigateUrl == Request.Path) { Menu1.SelectedItem.Selectable = false; } } 此致, Walter Wang(wa****@online.microsoft,删除''在线。'') Microsoft在线社区支持 ==== ============================================== 通过电子邮件收到我的帖子通知?请参阅 msdn.microsoft / subscripti ... ult.aspx#notif ications。如果您使用的是Outlook Express,请确保清除 复选框工具/选项/读取:一次获取300个标题及时看到你的回复 。 注意:MSDN托管新闻组支持服务是针对非紧急问题 其中来自社区或Microsoft支持的初步响应 工程师可在1个工作日内完成。请注意,每个跟随 的响应可能需要大约2个工作日作为支持 专业人士与您合作可能需要进一步调查才能达到 最有效的分辨率。该产品不适用于需要紧急,实时或基于电话的交互或复杂的b $ b项目分析和转储分析问题的情况。这种性质的问题最好通过联系 Microsoft客户支持服务(CSS)处理 href =msdn.microsoft/subscriptions/support/default.aspx\"target =_ blank> msdn.microsoft/subscripti...t/default.aspx 。 ======================================== ========== 此帖子按原样提供。没有保证,也没有授予任何权利。

Using the new ASP.NET 2.0 menu control on a master page. Is there any way to NOT have the current page be a live link and ideally also have it appear in a different style? Similar to the sitemappath control''s RenderCurrentNodeAsLink property. TIA -- AG Email: discuss at adhdata dot com

解决方案

"AG" <NO**********@newsgroups.nospamwrote in message news:%2****************@TK2MSFTNGP02.phx.gbl...

Using the new ASP.NET 2.0 menu control on a master page. Is there any way to NOT have the current page be a live link and ideally also have it appear in a different style? Similar to the sitemappath control''s RenderCurrentNodeAsLink property.

I don''t think it''s possible just with the <asp:Menu>''s properties. Dead easy in code, though...

Care to give a hint? -- AG Email: discuss at adhdata dot com "Mark Rae" <ma**@markNOSPAMraewrote in message news:en**************@TK2MSFTNGP03.phx.gbl...

"AG" <NO**********@newsgroups.nospamwrote in message news:%2****************@TK2MSFTNGP02.phx.gbl...

>Using the new ASP.NET 2.0 menu control on a master page.Is there any way to NOT have the current page be a live link and ideallyalso have it appear in a different style?Similar to the sitemappath control''s RenderCurrentNodeAsLink property.

I don''t think it''s possible just with the <asp:Menu>''s properties. Dead easy in code, though...

Hi AG, If you are using DataBinding on the Menu control, you can handle it''s DataBound event and change current item: protected void Menu1_DataBound(object sender, EventArgs e) { if (Menu1.SelectedItem.NavigateUrl == Request.Path) { Menu1.SelectedItem.Selectable = false; } } Sincerely, Walter Wang (wa****@online.microsoft, remove ''online.'') Microsoft Online Community Support ================================================== Get notification to my posts through email? Please refer to msdn.microsoft/subscripti...ult.aspx#notif ications. If you are using Outlook Express, please make sure you clear the check box "Tools/Options/Read: Get 300 headers at a time" to see your reply promptly. Note: The MSDN Managed Newsgroup support offering is for non-urgent issues where an initial response from the community or a Microsoft Support Engineer within 1 business day is acceptable. Please note that each follow up response may take approximately 2 business days as the support professional working with you may need further investigation to reach the most efficient resolution. The offering is not appropriate for situations that require urgent, real-time or phone-based interactions or complex project analysis and dump analysis issues. Issues of this nature are best handled working with a dedicated Microsoft Support Engineer by contacting Microsoft Customer Support Services (CSS) at msdn.microsoft/subscripti...t/default.aspx. ================================================== This posting is provided "AS IS" with no warranties, and confers no rights.

更多推荐

菜单控制

本文发布于:2023-11-25 15:55:35,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1630387.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:菜单

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!