Hello,
I am presently using Blazor Server-side for an Learning Management System type format assignment. Presently we have our login pages, dashboard, profile page, etc. already created with navlinks in the navmenu. However, after a user first logs in, we have it redirect to their "dashboard", but the navmenu is not updating (presently all they can see is "Home" until they login, then it should show all navlinks). So after they login, they have to hit "Home" navlink in the navmenu, before it will refresh and display all the other navlinks (Dashboard, Profile, Registration, etc.).
My question is, how do I force the navmenu to update, as soon as they login and are redirected to the dashboard page? So that the user doesn't have to click "home" navlink to update it.
Thank you for your help.
Jay Krishna ReddyPosted Jun 27, 2021, 5:06 AM
This page will immediately redirect to your original page refreshing the page and all of the data instantly.
You can create a refresh method in your original page as follows:
This solves the issue you mention much faster than any of the other solutions provided so far:
You can also use this to pass parameters into your refresh page by adding the following to the refresh page: