accessing documents properties in code

G

Guest

Is it possible to access the page's document properties in code? I am specifically looking for an easy way to insure that the margins of the body are always a fixed size. I can do this by registering a script block that contains an inline style definition, but this seems like a complete hack. There are also tons of great document properties that I would like to be able to set from C# code in the page_load event. If I use the properties panel from the designer, most of these get rendered into the <body> tag. It would be great if I could control this rather than relying on programmers to set these properties manually in each page

Thanks in advance
Mat
 
K

Kevin Spencer

How about using an external CSS Style Sheet?

--
HTH,
Kevin Spencer
..Net Developer
Microsoft MVP
Big things are made up
of lots of little things.

mslyh said:
Is it possible to access the page's document properties in code? I am
specifically looking for an easy way to insure that the margins of the body
are always a fixed size. I can do this by registering a script block that
contains an inline style definition, but this seems like a complete hack.
There are also tons of great document properties that I would like to be
able to set from C# code in the page_load event. If I use the properties
panel from the designer, most of these get rendered into the <body> tag. It
would be great if I could control this rather than relying on programmers to
set these properties manually in each page.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,537
Members
45,020
Latest member
GenesisGai

Latest Threads

Top