views:

88

answers:

3

Totally new to Silverlight (and XAML), but a long-time c# developer. I am building an app that will look similar to this: alt text

Basically the user clicks on a node in the tree (Panel 1) and new content appears in Panel 3.

In Winforms, I would have just built a UserControl for each node and just swap the Panel 3 based on the node clicked. But I am pretty sure there is something better out there for Silverlight.

So how do I architect this puppy?

I should add one thing...I am on a tight schedule and don't have time to build complicated frameworks. The solution must be simple to grok for both me and the person who ends up maintaining the app.

+1  A: 

Well first of all, throw everything you know about WinForms out the window.

To implement what you said, learning to use "navigation" in Silverlight 3 would be what you need. See here

vidalsasoon
A: 

Yes learn navigation. And the TreeView control in the Silverlight toolkit should help with this.

silverArc
+1  A: 

While the navigation stuff looks interesting, I've not used it, and I'm honestly not sure it would simplify your app all that much.

Definitely check out the widgets in the Silverlight Toolkit, as silverArc suggested, but I'd probably go with your gut and create UserControls for Panel 3.

Depending on the data types needed, control over editable fields, and the data source you are pulling from, you might be able to create a simple reusable control that can generate that little grid on the fly. It could have a method on it like:

AddRowToGrid(string caption, string value)
{
  //dynamically add a label with the given caption to the grid
  //dynamically add a text box with the value to the grid
}

If they need to be editable, just change the value to an object-to-bind-to in the method declaration, and set the text box up with basic data binding.

~Chris

Chris Jaynes