Velocity Reviews

Velocity Reviews (http://www.velocityreviews.com/forums/index.php)
-   ASP .Net (http://www.velocityreviews.com/forums/f29-asp-net.html)
-   -   Re: Setting contents of style sheet at run-time (http://www.velocityreviews.com/forums/t84377-re-setting-contents-of-style-sheet-at-run-time.html)

Juno 08-06-2004 10:48 PM

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" <BillBorg@discussions.microsoft.com> wrote in message
news:48BAA37C-CD94-4CB6-AB2F-AD82C196BCA4@microsoft.com...
> 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?= 08-06-2004 11:45 PM

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" <BillBorg@discussions.microsoft.com> wrote in message
> news:48BAA37C-CD94-4CB6-AB2F-AD82C196BCA4@microsoft.com...
> > 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

>
>
>



All times are GMT. The time now is 07:09 AM.

Powered by vBulletin®. Copyright ©2000 - 2013, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, 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 47 48 49 50 51 52 53 54 55 56 57