David Sherwood

David Sherwood

  • NA
  • 11
  • 920

wpf how to prevent treeview exceeding window size

Dec 8 2021 9:58 PM

I would like my TreeView to stay within the availabe space within the window. By default the height grows as large as ncessary exceeding the window height. I can set MaxHeight to make it fit, but this wont be adjusted if the window gets taller. 

How can I make the height adjust to window size but not exceed it?


Answers (2)