Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Disable GridViewColumn Resize

Is there any way by which I can disable GridViewColumn resize in WPF? I don't want to style the control.

like image 760
Elmo Avatar asked Jul 29 '11 08:07

Elmo


1 Answers

See this link: Fixed-Width Column in ListView: A Column that cannot be resized

A fixed-width column is a column that cannot be resized by mouse dragging or double-clicks. You can find instances in outlook. Currently two methods can be used to achieve the effect. One is to restyle GridViewColumnHeader to remove the gripper inside its Template. The other is to subclass GridViewColumn to restrict columns' width to a fixed size.

like image 135
Fredrik Hedblad Avatar answered Nov 01 '22 03:11

Fredrik Hedblad