Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. Web Development
  3. ASP.NET
  4. Inheritance and page templates

Inheritance and page templates

Scheduled Pinned Locked Moved ASP.NET
htmlasp-netwpfcomsysadmin
1 Posts 1 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • E Offline
    E Offline
    EnkelIk
    wrote on last edited by
    #1

    Hi all. I am developing a website and since most pages on the site should have the same basic functionality and layout, I implemented a base template from which the other pages inherits, after reading Peter Provost's excellent article (http://www.codeproject.com/aspnet/page\_templates.asp). Now I have found that I really would like to split the template into one basic, and one a bit more developped that in its turn inherits from the basic one. Then some pages will inherit from the basic and others from the more advanced, and they will all have the functionality of the basic one. However I have not been able to figure out how to make the two step inheritance work: I want to add some html-controls in the more advanced template, preferably from the code behind, and additional controls in the child pages (directly in the aspx-file, or from the code behind -either one would be ok). I tried overriding GenerateHtmlForm() in the advanced template, but got the error that there could only be one form, runat at server in a page. Any good ideas? Is it at all possible to make inheritance work in more than one step with aspx? Thanks /EnkelIk

    1 Reply Last reply
    0
    Reply
    • Reply as topic
    Log in to reply
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes


    • Login

    • Don't have an account? Register

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • World
    • Users
    • Groups