hi,
i have created a aspx page template by creating a template.cs file which
inherits from the page class. In this file I override the OnInit event and
create a template in the form of a header, left menu and a footer. there is
also a body area where the main content of the page will go.
i created these 4 areas by dynamically creating a placeholder in each area
at runtime. in the template.cs i load user controls into each area except
for the body area (as this is meant to be populated by the main aspx page).
in my aspx page (which inherits the template class) if i create controls at
runtime i can simply reference the placeholder in the main body area, and
add a control to it at runtime.
my problem is that if i try and create controls at design time in my aspx
page, they appear before the header, rather than in the main body area.
i had a feeling i was creating my template in a wrong way when i did it,
because i was generating html code in my .cs file and it's hard to
read/maintain when you have several table cells.
can anyone please give me an example of how to create a template with a
header, left menu and a footer?
i have examples on the net but they all seem to be doing it in different
ways.
ps: i am a beginner to asp.net. 1 1483
Check out this article, this will help you. Here i have explained the basic
stuff of Page Template, how you need to create page templates. I have also
given links to various article which talks about Page Template http://www.microsoft.com/india/msdn/articles/87.aspx
--
Saravana
Microsoft India Community Star,MC** www.ExtremeExperts.com
"suzy" <me@nospam.co m> wrote in message
news:Oq******** ******@tk2msftn gp13.phx.gbl... hi,
i have created a aspx page template by creating a template.cs file which inherits from the page class. In this file I override the OnInit event
and create a template in the form of a header, left menu and a footer. there
is also a body area where the main content of the page will go.
i created these 4 areas by dynamically creating a placeholder in each area at runtime. in the template.cs i load user controls into each area except for the body area (as this is meant to be populated by the main aspx
page). in my aspx page (which inherits the template class) if i create controls
at runtime i can simply reference the placeholder in the main body area, and add a control to it at runtime.
my problem is that if i try and create controls at design time in my aspx page, they appear before the header, rather than in the main body area.
i had a feeling i was creating my template in a wrong way when i did it, because i was generating html code in my .cs file and it's hard to read/maintain when you have several table cells.
can anyone please give me an example of how to create a template with a header, left menu and a footer?
i have examples on the net but they all seem to be doing it in different ways.
ps: i am a beginner to asp.net.
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Rainer Herbst |
last post by:
Hi *,
please consider the following problem:
I have a XML document which includes some html elements.
I want to replace only the <div> element:
I specified two templates, one matches everything ("*"),
one matches only the "div". As far as I understand, the most specific
rule should apply, i.e. the div rule if the element is a <div>.
|
by: MArc Baumgartner |
last post by:
Hello all,
I have got a Question about XSL:FO:
A XML-File contains any customers. For every customer I have to
generate a letter. This letter can contain - depending on the
information about the customer - from 1 to 5 pages.
On every page I have to put the relative page number (e.g. 1-5) and
the absolute page number (e.g. 456). All letter should be in one
|
by: .:mmac:. |
last post by:
I have a bunch of files (Playlist files for media player) and I am trying to
create an automatically generated web page that includes the last 20 or 30
of these files. The files are created every week and are named XX-XX-XX.ASX
where the X's represent the date i.e. 05-22-05.asx
The files are a specific format and will always contain tags like the
following:
<TITLE>My media file title</TITLE>
<AUTHOR>Media file author</AUTHOR>
<Ref href =...
|
by: Random |
last post by:
I'm confused about the proper use and usefulness of namespaces. I beleive I
understand the purpose is so the developer can put classes within namespaces
to essentially organize your code. And I understand that you declare your
intention to use a namespace within a page through the "Inherits" attribute.
I know that using "Inherits" isn't absolutely necessary, it's just
recommended so the developer doesn't have to type out the entire...
|
by: cgaden |
last post by:
Hi everyone,
I have a problem that I've been trying to figure out for a while but I
just can't seem to get it right. I have the following XML fragment:
<Page ID="x1" Schema="Folder">
-<Page ID="x10" Schema="Common">
--<Page ID="x100" Schema="Common" />
--<Page ID="x200" Schema="Common" />
--<Page ID="x300" Schema="Common" />
| |
by: yinglcs |
last post by:
Hi,
I have a newbie XSLT question. I have the following xml, and I would
like to
find out the children of feature element in each 'features' element.
i.e. for each <featuresI would like to look up what each feature
depends on and gerenate a text file. For example, in the following
file, I would like to find out feature A depends on A1 and A2 and
feature B depends on B1 and B2. And write that to a text file.
|
by: TS |
last post by:
Steven, i lost this message conversation from outlook express and made a
post online (see last one on this page). Please answer it as it hasn't been
yet.
thanks
The clientID of our controls have become very long since
we have 2 master
pages that our pages inherit from. Some team members at
|
by: Goran Djuranovic |
last post by:
Hi all,
I am experiencing a strange thing happening with a "designer.vb" page. Controls I manually declare in this page are automatically deleted after I drop another control on a ".aspx" page.
- Why is this happening?
- Can I disable automatic declaration and have everything be declared manually?
- Any other options to fix this?
Thanks in advance.
Goran Djuranovic
|
by: thuythu |
last post by:
Please help me....
I used and Javascript to view the data. But when i click button open a popup windows, then select data and click save button. The popup close and return the main page, but the textbox value in the main page is undefined
----------------------------------------
here are code main page:
-------------------------------------------
<script language="JavaScript">
var thedata;
var newwin;
var thenumber;
function...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
| |
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
| |
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
| |