By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,963 Members | 1,261 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,963 IT Pros & Developers. It's quick & easy.

Newbee question on inheriting an user control?

P: n/a
Hi,

I have one user control named Schedule.ascx, I want to create another
control which is quite similar to schedule.ascx but differs in some methods
and some UI elements, the way I am doing it right now, I save schedule.ascx
as another name, say schedule2.ascx then I go to code behind and chane the
class name and the methods I like to change. Also modify the UI on ascx
file.

This is working. But there is a problem, evertime I change Scedule.ascx ,
either method and UI , I have to copy it to schedule2.ascx. Is there a
better way to do this? I imagine inheritance could help, just don't know
how to apply to this case.

TIA

Nov 19 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
You're saying you have to copy it to Schedule2.ascx. But you did'nt mention
Why. Are you recieving an error?

"Danny Ni" <dn*@yahoo.com> wrote in message
news:uv****************@TK2MSFTNGP14.phx.gbl...
Hi,

I have one user control named Schedule.ascx, I want to create another
control which is quite similar to schedule.ascx but differs in some methods and some UI elements, the way I am doing it right now, I save schedule.ascx as another name, say schedule2.ascx then I go to code behind and chane the
class name and the methods I like to change. Also modify the UI on ascx
file.

This is working. But there is a problem, evertime I change Scedule.ascx ,
either method and UI , I have to copy it to schedule2.ascx. Is there a
better way to do this? I imagine inheritance could help, just don't know
how to apply to this case.

TIA

Nov 19 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.