I am working in SL version 2.0
I have 3 radio buttons in a group and 3 user controls that I want to load based on the selection of the radio button. How can this be done? What options do I have?
I was thinking about adding the user controls in the same xaml file as the radio buttons, and make them all invisible. Then on the code behind depending on the selection of the radio buttons make them visible.
Is that the only solution or is there a more effective way to do this?
Thanks in advance.
Depending on the size and complexity of those controls, your solution may be reasonable.
There are other methods, including dynamically loading modules. This adds significant complexity. Prism is the foremost project for this in Silverlight, and can be found at http://compositewpf.codeplex.com/.
10 things to know about Prism : http://www.sparklingclient.com/prism-silverlight/
Podcast on intro to Prism : http://www.sparklingclient.com/prism-in-silverlight/