Control Event

S

shapper

Hello,

I am working on a Custom control which inherits from Composite
Control.
I perform a few actions on Init, Load and PreRender events of this
control.

How can I access this events inside my custom control code?

Thanks,
Miguel
 
M

Manish

Hi Miguel,

You can try the following code to achieve this.

public class MyControl : CompositeControl
{
public MyControl()
{
//
// TODO: Add constructor logic here
//
}

protected override void OnInit(EventArgs e)
{
base.OnInit(e);
}

protected override void OnLoad(EventArgs e)
{
base.OnLoad(e);
}

protected override void OnPreRender(EventArgs e)
{
base.OnPreRender(e);
}
}

Regards,
Manish
www.ComponentOne.com
 

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

Similar Threads

Event 1
Event 0
Control, Web Control and Composite Control 6
Control Event 3
Page and Control Event Sequence 1
Event 2
Event 0
Event 0

Members online

Forum statistics

Threads
473,773
Messages
2,569,594
Members
45,119
Latest member
IrmaNorcro
Top