Navigation menu changes in VS do not reflect in Radzen

I have like 50+ pages.
using the navigation menu tool in Radzen is a lot of work,
I tried changing in MainLayout.razor, but the change isn't picked up in Radzen.
I know you have to exclude MainLayout.razor in Radzen so it won't be overwritten while running Radzen.
Can Radzen pick up the changes done in Visual Studio ?

No. Radzen generates code on meta data.

Ok As I understand it is a one way. Can I manipulate the meta data manually and where is it located ?

You can edit the navigation from design time. There is a button which adds all pages to the menu and later you can rearrange them. More info is available in the Custom navigation menu help article.

You can manipulate the metadata but you have to be careful. I recommend following the steps from the article mentioned above and then editing the meta\layouts\main.json file if you still need to.

1 Like

There is a difference in the visiblity with generated menus and manually added menus.
the generated have Visible="@Security.IsInRole(new string[]{"Authenticated"})"
whilest the newly added do not have a 'Visible' tag.
e.g.:
manyally added :

generated bij population :
<RadzenPanelMenuItem Path="base-countries" Text="Base Countries" Visible="@Security.IsInRole(new string[]{"Authenticated"})">

Can I add this Visible condition to the manually added menus in the Radzen interface ?

Hey @SYSTENZ,

Yes, you can add the same expression to the manually added items Visible property however we will add it automatically when items are populated from the application with our next update.

1 Like