Link to home
Start Free TrialLog in
Avatar of chang2008
chang2008Flag for Germany

asked on

Disable resize

Hello all,

I program with WPF. How can I disable resize?  

myFile.xaml

<UserControl>
     <Grid>
          <TreeVeiw>
          </TreeView>
     </Grid>
</UserControl>

Thank you very much in advance. :)
Avatar of jagrut_patel
jagrut_patel
Flag of India image

Set same value of UserControl's MinHeight and MaxHeight properties to control height and set same value of MinWidth and MaxWidth properties to control the width.

e.g.
<UserControl ..... MinHeight="100" MaxHeight="100" MinWidth="200" MaxWidth="200">
ASKER CERTIFIED SOLUTION
Avatar of Kalpesh Chhatrala
Kalpesh Chhatrala
Flag of India image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of chang2008

ASKER

I did like this & it works.

Window window = new Window();
window.ResizeMode = ResizeMode.NoResize;

Thanks