Problem with System.Windows.Forms.Design.FileNameEditor

  • Thread starter Thread starter Polo
  • Start date Start date
P

Polo

Hi,

I have a class CustomFileNameEditor that inherits from FileNameEditor
I override the method "InitializeDialog" to customize the filter property
When I run the application this method is called only one time.

The problem is that the filter property can be change for each instance of
the class that has the CustomFileNameEditor
 
hi,

it's not clear what you want , you can pass those parameters in the
constructor and then use then inside the method:

string var;
public MyConstructor( string param1 )
{
this.var = param1;
}
protected override InitializeDialog( ... )
{
this.SomeProperty = var;
}


hth

cheers,
 
In fact, the problem is :

I assign an object on the property grid, I click on the button to select a
file the method InitializeDialog is called
If I click again on this button the method InitializeDialog isn't called.
It's the same if I change the selected objet of the propertyGrid (when I
click, the method InitializeDialog isn't called)
 
Back
Top