Re: [DOTNET] Programmatically accessing Webform HTML
by Thomas Tomiczek other posts by this author
Nov 23 2001 4:52PM messages near this date
Re: [DOTNET] Question: How to show a menu on a NotifyIcon when th
e user clicks (left, once)?
|
[DOTNET] Aesthetics Question on the CodeDOM
Ok, that's a simple version for the case that the author explicitly
limited it to - but you need to make the body attribute a generic
control. What if a user control wants to add something to the body tag
(which, to my shame, was more what I had in mind - SORRY for the wrong
post here)?
Thomas Tomiczek
THONA Consulting Ltd.
Microsoft MVP (.NET / C#)
-----Original Message-----
From: Jim Arnold [mailto:Jim.Arnold@[...].COM]
Sent: Freitag, 23. November 2001 17:41
To: DOTNET@[...].COM
Subject: Re: [DOTNET] Programmatically accessing Webform HTML
Body.Attributes["bgcolor"] = "green";
...
<body id=Body runat=server>
(It's an HtmlGenericControl)
Jim
-----Original Message-----
From: Thomas Tomiczek [mailto:t.tomiczek@[...].COM]
Sent: 23 November 2001 16:38
To: DOTNET@[...].COM
Subject: Re: [DOTNET] Programmatically accessing Webform HTML
The next one with this wish :-)
If you find an answer elsewhere, please post it to the list, too -
that's a sometimes necessary thing (especially with the Body tag),
though I think you will find out it is not possible. The HTML does not
exist in a form that is more organized tan a data stream. The stream is
constructed dynamically, and I do not thing you can just add a tag to
the body tag.
BUT - this is only my opinion, I never tried it out severely, so I might
err here.
Thomas Tomiczek
THONA Consulting Ltd.
Microsoft MVP (.NET / C#)
-----Original Message-----
From: Greg Gates [mailto:ggates@[...].CA]
Sent: Freitag, 23. November 2001 17:31
To: DOTNET@[...].COM
Subject: [DOTNET] Programmatically accessing Webform HTML
Hello
I would like to programmatically access the elements that exist in the
HTML
view of a Webform from the code behind (aspx.cs) file.
Specifically, I wish to to add an attribute to the BODY element at
runtime.
It's not clear to me how to get at the BODY element from the code behind
page, if it is indeed possible.
thanks, Greg
You can read messages from the DOTNET archive, unsubscribe from DOTNET,
or
subscribe to other DevelopMentor lists at http://discuss.develop.com.
You can read messages from the DOTNET archive, unsubscribe from DOTNET,
or
subscribe to other DevelopMentor lists at http://discuss.develop.com.
You can read messages from the DOTNET archive, unsubscribe from DOTNET,
or
subscribe to other DevelopMentor lists at http://discuss.develop.com.
You can read messages from the DOTNET archive, unsubscribe from DOTNET, or
subscribe to other DevelopMentor lists at http://discuss.develop.com.
|