Dynamic User Controls Raise Events

A

Anil.Narla

Hi,
I created a Base Control Code Behind class which contains a delegate
and event(both declared as public)
and i have all my user controls inheriting from this base control.

Now I have one page which loads one of the above user controls
@runtime.When user clicks on next button on a user control iwant to
raise the event that was declared in my base class which passes id for
the next control and my page will load that user control(it removes
current control and add the next control), But i'm getting compilation
error saying that base class event can be

"The event 'namespacetest.BaseControl.Redirect' can only appear on the
left hand side of += or -= (except when used from within the type
'namespacetest.BaseControl')
"

Please Post the solution.
 

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
474,262
Messages
2,571,056
Members
48,769
Latest member
Clifft

Latest Threads

Top