1

Given that you're creating a User Control in WPF that will be displayed on different screen resolutions, what's the best way to layout a dense collection of "input form" elements?

For example, labels, textboxes for text, dropdowns, group boxes, etc.

Do you create a master "grid" and use StackPanels and WrapPanels like crazy? What's the cleanest way to do this?

Brandon
  • 13,956
  • 16
  • 72
  • 114

1 Answers1

2

My way of doing it is like you described - master Grid with tons of StackPanels and Grid.Row="" statements. However you might try looking at this question and the top answer. The DockPanel looks promising, and I think next time I make a dense input form, I'll try using it.

A really concise tutorial can be found here.

Community
  • 1
  • 1
Phil
  • 6,561
  • 4
  • 44
  • 69
  • Most of my UI's use combinations of these panels, nested in a hierarchy. A GridPanel maybe on the outside, with individual cells containing StackPanels or other. – Cheeso Mar 07 '10 at 12:10