Using a propertyGrid control
-
Hi, I'm struggling with a property grid control. Here is what I do: - I display properties associated to a specific object in the property view. - For each property, I use a specific editor and allows value to be changed in another form. Each property has access to a specific editor which inherits from 'UITypeEditor'. - In the EditValue method of my editor, I call my form using the 'ShowDialog' method. Here is the beginning of my EditValue method:
public override object EditValue(ITypeDescriptorContext context, IServiceProvider provider, object value) { string startingPropertyValue = null; // The value that the property had before we display the modal form. PropertySpec currentPropertySpec = null; if (context != null && context.Instance != null && provider != null) //if (provider != null) { editorService = provider.GetService(typeof(IWindowsFormsEditorService)) as IWindowsFormsEditorService; }
My problem is that I'm not able to retrieve the values selected in my second form and display them for each selected property. Can you help me please ? Thanks. Pat.p.f. Goudjo-Ako Bringing our energy together !