I would like to two windows in WPF. I would like to show a screen to the user based on the settings in app.config. Since i am new to WPF, please help me regarding this.
Asked
Active
Viewed 569 times
2 Answers
0
You can use dynamic change content strategy
which well described here: Changing content dynamically in wpf window

Community
- 1
- 1

Mitklantekutli
- 410
- 1
- 3
- 16
-
I wanted it based on app config value – curiousdev Nov 17 '15 at 19:48
-
And whats the problem? You can switch content controls when window loads depending on logic from app config – Mitklantekutli Nov 19 '15 at 12:51
0
Based on your question, I think you want to select Window during startup. You can do this by modifying the App.xaml. Please refer this link for full details
If you want to do it during runtime easier option would be to modify your design to have user controls rather than windows. Then you can hide/disable functionality of the relevant control during run time.
-
No its not working. Its throwing error like its not able to find Application_Startup – curiousdev Nov 17 '15 at 19:42
-
hi, are you getting compilation or run time error?. Please follow the steps in the link. I just retested and it works – karpanai Nov 18 '15 at 10:23