Visual inheritance

B

Bart Schelkens

Hi,

I'm still using VB.NET 2002.
I was wondering if I could do the following :

I'm creating a web-application.
Now I want to create a base-webform that contains the layout for all my
pages.
Would it then be possible to inherite my new webforms from that
base-webform?
How would I do this?

Thanks in advance.
 
R

recoil

It is possible to do it but both VS.NET 2002 and 2003 have lots of
problems with these. Your controls that are in the markup are not
inherited. Only the code is inherited.
 
B

Brock Allen

You can do inheritance and have the base class' controls work with the derived
classes' controls. There is no support in VS.NET though for visual inheritance
as there is in Windows Forms.
 
P

Patrice

No. You inherits only the code. You have AFAIK several options here :
- you should find on the Internet some controls for doing this
- depending on the appearence you could create the common appearance by code
(and as you inherits code it works though you'll looose design time support
for this part)
- some are doing something similar by loading user controls on a "template"
page

ASP.NET 2.0 will add somthing similar to solution #1 out of the box (this is
called "master pages").

Patrice
--
 

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,995
Messages
2,570,228
Members
46,818
Latest member
SapanaCarpetStudio

Latest Threads

Top