Professional Web Applications Themes

Template Questions, Site Design Suggestions, ASP.NET Newbie - ASP.NET General

Jordan, you need to use asp.net Page Templates. [url]http://www.aspnetui.com/templates/[/url] i am trying to do the same thing and still can't get it to work the way i want to. :( "Jordan Marton" <JMartonHAHAmarketaxess.com> wrote in message news:Op3rtuoVDHA.2260TK2MSFTNGP09.phx.gbl... > Hi There! > > This is my first post to these newsgroups, so I hope I'm asking in the right > place. I am currently a comfrotable ASP 3.0 developer, and use Dreamweaver > MX and Access databases to make my sites. One of the handiest features of DW > was templates, as it enabled me to keep all pages constant. > ...

  1. #1

    Default Re: Template Questions, Site Design Suggestions, ASP.NET Newbie

    Jordan, you need to use asp.net Page Templates.

    [url]http://www.aspnetui.com/templates/[/url]

    i am trying to do the same thing and still can't get it to work the way i
    want to. :(


    "Jordan Marton" <JMartonHAHAmarketaxess.com> wrote in message
    news:Op3rtuoVDHA.2260TK2MSFTNGP09.phx.gbl...
    > Hi There!
    >
    > This is my first post to these newsgroups, so I hope I'm asking in the
    right
    > place. I am currently a comfrotable ASP 3.0 developer, and use Dreamweaver
    > MX and Access databases to make my sites. One of the handiest features of
    DW
    > was templates, as it enabled me to keep all pages constant.
    >
    > As I am now learning ASP.NET and have just purchased VisualBasic.Net 2003,
    I
    > was wondering if it is possible to achieve the same sort of "template"
    site
    > design as I am yused to.
    >
    > I understand that user controls can be included on every page, and
    therefor
    > I'd only have to edit each control to change the site. But I mean if I
    need
    > to add an additional user control to every page, then thats a lot harder
    > than addining a new control once to the main template and having all other
    > pages inherit that.
    >
    > Any ideas comments suggestions?
    >
    > Thanks
    > Jordan
    >
    >

    suzy Guest

  2. #2

    Default Re: Template Questions, Site Design Suggestions, ASP.NET Newbie

    For templates:
    Create a class in your ASP.net Project and have it inherit from the Page object like this:
    Public Class cMyTemplate : Inherits System.Web.UI.Page

    then you'll need to override teh Render method like so

    Protected Overrides Sub Render(ByVal writer As System.Web.UI.HtmlTextWriter)

    'Create your header here with response.writes etc etc

    mybase.render(writer)

    'create your footer here



    When you add a new webform to the project, look in the code behind file. You'll see at the top that it inherits from System.Web.UI.Page. Change System.Web.UI.Page to cMyTemplate (or whatever you called it).

    Now, when your new webform is rendered, it will write out a header, write out whatever is in the webform (that's the mybase.render ) and then render out a footer.

    It's quick and fast. Also, if you look at teh IBuySpy portal example, they give you a another way to do similar things with WebUserControls. A Web usercontrol is similar to an Include fiel in ASP 3.0



    Michael

    "Jordan Marton" <JMartonHAHAmarketaxess.com> wrote in message news:Op3rtuoVDHA.2260TK2MSFTNGP09.phx.gbl...
    > Hi There!
    >
    > This is my first post to these newsgroups, so I hope I'm asking in the right
    > place. I am currently a comfrotable ASP 3.0 developer, and use Dreamweaver
    > MX and Access databases to make my sites. One of the handiest features of DW
    > was templates, as it enabled me to keep all pages constant.
    >
    > As I am now learning ASP.NET and have just purchased VisualBasic.Net 2003, I
    > was wondering if it is possible to achieve the same sort of "template" site
    > design as I am yused to.
    >
    > I understand that user controls can be included on every page, and therefor
    > I'd only have to edit each control to change the site. But I mean if I need
    > to add an additional user control to every page, then thats a lot harder
    > than addining a new control once to the main template and having all other
    > pages inherit that.
    >
    > Any ideas comments suggestions?
    >
    > Thanks
    > Jordan
    >
    >

    ---
    Outgoing mail is certified Virus Free.
    Checked by AVG anti-virus system ([url]http://www.grisoft.com[/url]).
    Version: 6.0.504 / Virus Database: 302 - Release Date: 7/24/2003
    Michael Pearson Guest

Similar Threads

  1. Inviting suggestions for client application design
    By yashgt@yahoo.com in forum ASP.NET Web Services
    Replies: 2
    Last Post: June 21st, 06:25 PM
  2. Flash Site design questions
    By bballplanet webforumsuser@macromedia.com in forum Macromedia Flash Sitedesign
    Replies: 5
    Last Post: January 16th, 05:13 AM
  3. comments & suggestions for my site design
    By ciecierega webforumsuser@macromedia.com in forum Macromedia Flash Sitedesign
    Replies: 0
    Last Post: September 13th, 02:02 AM
  4. Replies: 0
    Last Post: September 12th, 07:06 PM
  5. VB.Net Template Idea Suggestions
    By Jordan Marton in forum ASP.NET General
    Replies: 4
    Last Post: August 5th, 05:38 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139