Go Back   Velocity Reviews > Newsgroups > ASP Net
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

Reply

ASP Net - Re: Setting contents of style sheet at run-time

 
Thread Tools Search this Thread
Old 08-06-2004, 11:48 PM   #1
Default Re: Setting contents of style sheet at run-time


Hi,

Put a Literal control on the page and in codebihide :
Literal1.Text = "<STYLE>.MyHeaderStyle { FONT-SIZE: 10pt; COLOR: black }
</STYLE> "

Thus ,you can modify MyHeaderStyle at the rumtime.

--
Juno
MCSD.NET, MCDBA, MCSE
----------------------------------------------------------
Support Team of EasyDotNet, INC. http://www.EasyDotNet.com
DataForm.NET - The most powerful data entry web server control for ASP.NET



"Bill Borg" <> wrote in message
news:48BAA37C-CD94-4CB6-AB2F-...
> Hello all,
>
> I am using a style sheet to format html output. Is there a way to override
> those style attributes at run-time?
>
> e.g. <span class=MyHeaderStyle>Some header...</span>
>
> I would like to pull from a database and set attributes of MyHeaderStyle

for
> font-size, color, etc.
>
> I'm thinking this is possible, but can't figure it out. Any help is
> appreciated.
>
> Thanks,
>
> Bill Borg





Juno
  Reply With Quote
Old 08-07-2004, 12:45 AM   #2
=?Utf-8?B?QmlsbCBCb3Jn?=
 
Posts: n/a
Default Re: Setting contents of style sheet at run-time
Brilliant, thank you.

"Juno" wrote:

> Hi,
>
> Put a Literal control on the page and in codebihide :
> Literal1.Text = "<STYLE>.MyHeaderStyle { FONT-SIZE: 10pt; COLOR: black }
> </STYLE> "
>
> Thus ,you can modify MyHeaderStyle at the rumtime.
>
> --
> Juno
> MCSD.NET, MCDBA, MCSE
> ----------------------------------------------------------
> Support Team of EasyDotNet, INC. http://www.EasyDotNet.com
> DataForm.NET - The most powerful data entry web server control for ASP.NET
>
>
>
> "Bill Borg" <> wrote in message
> news:48BAA37C-CD94-4CB6-AB2F-...
> > Hello all,
> >
> > I am using a style sheet to format html output. Is there a way to override
> > those style attributes at run-time?
> >
> > e.g. <span class=MyHeaderStyle>Some header...</span>
> >
> > I would like to pull from a database and set attributes of MyHeaderStyle

> for
> > font-size, color, etc.
> >
> > I'm thinking this is possible, but can't figure it out. Any help is
> > appreciated.
> >
> > Thanks,
> >
> > Bill Borg

>
>
>



=?Utf-8?B?QmlsbCBCb3Jn?=
  Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
This is incredible! jc_ice DVD Video 1 08-13-2006 10:47 AM
fwd: Copyright law caught in its own time warp Netmask DVD Video 3 07-23-2006 02:40 AM
Cannot erase DVD-RW Terry Pinnell DVD Video 54 10-09-2005 10:14 PM
As growth slows, Hollywood faces a DVD standoff. Allan DVD Video 0 07-11-2005 02:10 PM
Re: 7. The truth about our creator. .7 john smith DVD Video 2 07-25-2003 03:54 AM




SEO by vBSEO 3.3.2 ©2009, Crawlability, Inc.

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