.NET control for providing a UI that allows the properties of one or more objects to be viewed and edited.
Questions tagged [propertygrid]
958 questions
3
votes
1 answer
Event not showing up in the Property Grid
I am creating a special search text box. Among other things it have these two events:
[Category("Behavior")]
public event EventHandler> Search;
[Category("Property Changed")]
public event…

Svish
- 152,914
- 173
- 462
- 620
3
votes
2 answers
C# PropertyGrid - How to make array elements read only?
I have a PropertyGrid to which I add a array of bool-values. The array itself is marked as ReadOnly, which is recognized properly by the property grid.
BUT: If I expand the array in the Grid, all the items are editable by the user. Of course that's…

Boris
- 8,551
- 25
- 67
- 120
3
votes
1 answer
Italic text in a PropertyGrid
I'm using a PropertyGrid to show custom properties that are exposed through the implementation of ICustomTypeDescriptor.
My objects are setup in a tree structure and values for each property are either set in each object or inherited from parent…

Eric Anastas
- 21,675
- 38
- 142
- 236
3
votes
3 answers
C# Properties: Font and Color Change on the Fly
Does anyone know how to change the font and the font color of the property value I am inputting? I am using Windows Forms and Propertygrid. Thank you.
I am thinking of using:
using( Font myFont = new Font("Arial", 8, FontStyle.Italic) ) but am not…

Zeos6
- 273
- 1
- 7
- 18
3
votes
1 answer
Automatically expand some properties in PropertyGrid
I would like to automatically expand some nodes in a PropertyGrid loaded with an instance of my SettingsStructure class by using attributes on the properties of that class.
Also, I am attempting to have the instance 'remember' whether each property…

John Kurtz
- 775
- 8
- 16
3
votes
1 answer
How to remove/hide 'Property Pages' button from a PropertyGrid?
I'm working on a propertyGrid panel and I'm trying to remove or hide Property Pages button as it is useless to me, I tried setting ToolBarVisible to false but that hides all the three buttons in the toolbar. Here is what my property grid looks…

Mahdi Benaoun
- 67
- 1
- 8
3
votes
4 answers
Programmatically Hide Property in PropertyGrid
Using
_
on the declaration of a class (which is a property of another class) that consists of a number properties.
I load an instance of this class with…

hmcclungiii
- 1,765
- 2
- 16
- 27
3
votes
1 answer
PropertyGrid scroll position not changing when set
I have a PropertyGrid in a Windows Forms application. Whenever its SelectedObject changes, it resets its VerticalScroll value to 0. I need it to remain where it was. The code below doesn't seem to do anything. I've tried PerformLayout and a bunch of…

Cliff
- 697
- 8
- 19
3
votes
2 answers
C# force PropertyGrid to not expand a sub-class property and display it at root level
I'm facing a display problem with PropertyGrid.
I have object called Product that have a property Fields as a List< Field > nested objects.
I used custom TypeConverters and PropertyDescriptors like in many articles available online and I achieved…

yo3hcv
- 1,531
- 2
- 17
- 27
3
votes
1 answer
How to make a Stripped Down PropertyGrid
I'm building an app where I show data in a tree view, and when a user double-clicks on an element in the tree view, the node they clicked on is replaced with an editable version of the node. The way different nodes are edited varies greatly, so…

Ed Marty
- 39,590
- 19
- 103
- 156
3
votes
2 answers
Propertygrid changes not picked up when using menu shortcut for saving
I am trying to implement a simple windows forms application, where the user can edit instances of a simple Person class. The application makes use of the standard propertygrid, assigning instances of the Person class to the SelectedObject property…

Ebbe
- 33
- 2
3
votes
3 answers
C# How to expose a property based on the value of another property in a propertygrid?
I have class with multiple properties. Sometimes a property (A) may be edited in a propertygrid. But sometimes property A may not be edited. This depends on a value of another property.
How can I do this?
EDIT:
I am sorry, I forget to mention that I…

Martijn
- 24,441
- 60
- 174
- 261
3
votes
2 answers
Choose time using datetimepicker in propertygrid
I am trying to pick only a time (hour and minutes) using propertygrid and datetimepicker.
I have created my own editor.
The trouble is that it is not showing the value in the text and the value can also have calendars:
Here have code:
public class…

guyl
- 2,158
- 4
- 32
- 58
3
votes
3 answers
Implementing validations in WPF PropertyGrid
I have implemented a PropertyGrid and properties of selected object(in another library) are displayed in it. Property values are bound to PropertyGrid controls through binding. Now, I want to perform validation on values user enters in PropertyGrid…

akjoshi
- 15,374
- 13
- 103
- 121
3
votes
1 answer
WinForms PropertyGrid with empty and non-empty Category
Is there any way to customize Winforms PropertyGrid, if it needs to show one element without category on top (full row) and several categories with elements inside below?

Lonli-Lokli
- 3,357
- 1
- 24
- 40