Skip to content

How do I do the first initial (module) navigation based on some condition? #2844

Closed Answered by brianlagunas
nivle asked this question in WPF
Discussion options

You must be logged in to vote

Anything is possible. It's just code. The reason navigation isn't working in your InitialSettingsModule is because you are trying to navigate to a view in a module that hasn't been loaded yet. So, the view doesn't exist yet. You can only navigate to views in other modules if those modules have been loaded. You just have to make sure all modules that contain the views you want to navigate to are loaded first. However, it sounds like you're trying to conditionally load your modules, not views. Why not wrap that logic around the module itself and only add it if meets your condition?

Replies: 2 comments 1 reply

Comment options

You must be logged in to vote
1 reply
@nivle
Comment options

Answer selected by nivle
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
WPF
Labels
None yet
2 participants