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

MasterPage RadMenu item visible only on 1 page

2 Answers 11 Views
Menu
This is a migrated thread and some comments may be shown as answers.
James
Top achievements
Rank 1
James asked on 11 Jul 2014, 09:05 PM
I have a RadMenu defined to my MasterPage and would like to have one of the items visible only on 1 page.  I set the visibility to false for that item in the MasterPage.vb is there a way to set that to true from another page that is using that MasterPage?

Thanks

2 Answers, 1 is accepted

Sort by
0
Accepted
Shinu
Top achievements
Rank 1
answered on 14 Jul 2014, 07:23 AM
Hi James,

Please try the below VB code snippet to achieve your scenario.

VB:
Protected Sub Page_Load(sender As Object, e As EventArgs)
    Dim menu As RadMenu = DirectCast(Me.Page.Master.FindControl("rmenuDemoItems"), RadMenu)
    menu.FindItemByText("Item1").Visible = True
End Sub

Thanks,
Shinu.
0
James
Top achievements
Rank 1
answered on 14 Jul 2014, 02:50 PM
That did the trick!.
Thank You
Tags
Menu
Asked by
James
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 1
James
Top achievements
Rank 1
Share this question
or