WPF DATAGRID AUTORESIZE ON MAXIMIZE

Royce Roy

Total Post:149

Points:1043
Posted by  Royce Roy
WPF 
WPF
 3061  View(s)
Ratings:
Rate this:

My WPF application has a resolution of 1024x768. I have a datagrid that fills a vertical half of the application. In higher resolutions, when I maximize I want the datagrid to automatically resize vertically and fill the entire height. How can I do this?

  1. Sumit Kesarwani

    Post:378

    Points:2694
    Re: WPF datagrid autoresize on maximize

    Hi Royce,


    You can try setting the control's vertical alignment to stretch (VeritcalAlignment="Stretch") so that even when your window resizes, it still fills up the vertical part of your screen.

Answer

NEWSLETTER

Enter your email address here always to be updated. We promise not to spam!