Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public static void SetLabelColumnWidth(System.Windows.Forms.PropertyGrid grid, int width)
- {
- FieldInfo fi = grid?.GetType().GetField("gridView", BindingFlags.Instance | BindingFlags.NonPublic);
- Control view = fi?.GetValue(grid) as Control;
- MethodInfo mi = view?.GetType().GetMethod("MoveSplitterTo", BindingFlags.Instance | BindingFlags.NonPublic);
- mi?.Invoke(view, new object[] { width });
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement