WebUserControl and design time support

C

Christian H

Hello,

I've just created a WebUserControl that consists of a few other controls
such as DropDownList, TextBox and Button.
Based on the information entered in the DropDownlist, and TextBox, the
Button.onClick event quries a database, and returns a DataTable.

Because I'm going to use this control different places, and bind the
DataTable in different ways (sometimes a datagrid, sometimes repeater) , I
added a delegate (OnButtonSearchClick) that handles the Button.onClick
event. The delagate also has a custom ButtonSearchEventArg to make things a
little easier.
This way I can add my WebUserControl to different Pages, hook up a
ButtonSearchClick event to the control, and use the ButtonSearchEventArg to
display my DataTable the way I want.

Now, this all works just fine, but I'm having a bit trouble with Design
support for my WebUserControl.
How can I get my delegate to appear in the Properties->Events toolbox window
?

Right now, I have to do it by hand , by writing
myControl.ButtonSearchClick+=new ButtonSearchEventHandler(...)

Is there any way of getting design time support for delegates, (and
properties as well ), for a WebUserControl ?

Thanks
Christian H.
 

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

Members online

No members online now.

Forum statistics

Threads
473,994
Messages
2,570,223
Members
46,810
Latest member
Kassie0918

Latest Threads

Top