User Control

F

Franck Diastein

Hi,

I'm designing an User Control, with TypeConverter...

If I use this:

private ImageList imageList = null;
public ImageList ImageList{
get {return this.imageList;}
set {this.imageList = value;}
}

And go to design mode to my User Control properties, I can *magically*
select one of the available ImageLists...

I would like to be able to hook to a component made by me, but if I do this:

private MyComponent mycomp = null;
public MyComponent Component{
get {return this.mycomp;}
set {this.mycomp = value;}
}

What 'magic' trick do I need in MyComponent so my User Control list all
MyComponent available in the working form...

I hope you understand this...

TIA
 
J

joeycalisay

Have you tried overriding TypeConverter.StandardValuesCollection
GetStandardValues(ITypeDescriptorContext context) method?
 
F

Franck Diastein

Thank you, this will help me...

BTW, I want to able to select a file aka Image property in PictureBox...

What do I need ?

TIA again.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top