Quantcast
Channel: Remove additional vertical whitespace from WPF - Stack Overflow
Browsing latest articles
Browse All 7 View Live

Answer by Dave Hanson for Remove additional vertical whitespace from WPF

You need to make the container that contains the ListBox to have a height of AUTOListBox1 is in a row of height AUTOListBox2 is in a row span of height *This'll allow you to have the correct height on...

View Article


Answer by Salvatore Previti for Remove additional vertical whitespace from WPF

Perhaps...<StackPanel LastChildFill="False">

View Article

Answer by Mohammad Zare for Remove additional vertical whitespace from WPF

If i understand your question correctly, you can use Height="Auto" for your listbox (or other controls) and if you want to keep your window's height updated according to the listbox, you can bind your...

View Article

Answer by Paul Walls for Remove additional vertical whitespace from WPF

The reason this is happening is because ListBox overrides the default ItemsPanelTemplate settings to use a VirtualizingStackPanel. It does this because VirtualizingStackPanel supports UI...

View Article

Answer by Joe White for Remove additional vertical whitespace from WPF

By default, controls will expand to fill all the space its container will give it. That's what you're seeing, and it's expected, since you didn't tell it to do anything else (i.e., you didn't set any...

View Article


Answer by Rachel for Remove additional vertical whitespace from WPF

Wrap your ListBox in a Grid and set it's VerticalAlignment="Top"It sounds like your ListBox control is inside another element such as a Grid or DockPanel, which by default stretches it's children to...

View Article

Image may be NSFW.
Clik here to view.

Remove additional vertical whitespace from WPF

<Border CornerRadius="2,2,2,2" BorderThickness="1" BorderBrush="LightSkyBlue" Margin="5,2,2,2" x:Name="PersonBorder" Visibility="Collapsed"><StackPanel Orientation="Vertical"><ListBox...

View Article
Browsing latest articles
Browse All 7 View Live