473,322 Members | 1,718 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,322 software developers and data experts.

Is this possible with themes?

ASP.NET 2.0

I have developed a webpage which are using themes, the webpage contain a
dropdownlist where the user can select the theme for the page...

This webpage (.aspx) contain a table (asp:Table). Here is my problem I want
to completely change the layout of the table based on what theme is
selected. For example one of the table cells contain a image (server
control) and by selecting another theme then I want the image to appear in
another table cell in the table - completely changing the layout of the
table, not just setting colors and such things... Is it possible??

If this is possible then please explain me how to do it!

Jeff
May 14 '07 #1
2 1258
maybe. themes only use css styles. if you switch from a table to divs,
then the css themes can control the layout.

-- bruce (sqlwork.com)

Jeff wrote:
ASP.NET 2.0

I have developed a webpage which are using themes, the webpage contain a
dropdownlist where the user can select the theme for the page...

This webpage (.aspx) contain a table (asp:Table). Here is my problem I want
to completely change the layout of the table based on what theme is
selected. For example one of the table cells contain a image (server
control) and by selecting another theme then I want the image to appear in
another table cell in the table - completely changing the layout of the
table, not just setting colors and such things... Is it possible??

If this is possible then please explain me how to do it!

Jeff

May 14 '07 #2
// Put the following into the Page_Load event and tell me what you see...
Page.Title = Page.Theme;

As you've learned we have to change the Theme from the Page_PreInit event
but we can access the current Theme from anywhere the Page is accessible.
Assuming you're using Visual Studio I have to ask if you've ever heard of
Intellisense :-) So build yourself a simple switch statement and put it into
the Page_Load event...

switch (Page.Theme)
{
case "Blue" :
// load the table you want here
break;
case "Green" :
// load the other table you want here
break;
default "Blue" :
// load the table you want as the default here
break;
}

Finally, before you get much deeper into the doo-doo you better do some
homework and learn the difference between the Theme and the StyleSheetTheme.
K. Scott Allen has documented both Master Pages and Themes extensively [1].

<%= Clinton Gallagher
NET csgallagher AT metromilwaukee.com
URL http://clintongallagher.metromilwaukee.com/

[1] http://odetocode.com/
"Jeff" <it************@hotmail.com.NOSPAMwrote in message
news:u%***************@TK2MSFTNGP05.phx.gbl...
ASP.NET 2.0

I have developed a webpage which are using themes, the webpage contain a
dropdownlist where the user can select the theme for the page...

This webpage (.aspx) contain a table (asp:Table). Here is my problem I
want to completely change the layout of the table based on what theme is
selected. For example one of the table cells contain a image (server
control) and by selecting another theme then I want the image to appear in
another table cell in the table - completely changing the layout of the
table, not just setting colors and such things... Is it possible??

If this is possible then please explain me how to do it!

Jeff

May 15 '07 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Full Decent | last post by:
Hey again! In my quest to make proper use of OO PHP I would like to ask for a critique of the current method of doing themes in the Camera Life (http://fdcl.sf.net) software and see if an OO...
3
by: Elridge | last post by:
I am planning to migrate our company's site ASP.NET 1.x to 2.0. We would like to use master pages and themes. However, we would like to keep our web project generic so that it can be applied to...
5
by: Jan Hyde | last post by:
I keep reading that there should be a couple of built in themes in the directory ...\Microsoft.NET\Framework\v2.x.xxxxx\ASP.NETClientFiles\Themes I've yet to see any machine with this 'Themes'...
3
by: johannblake | last post by:
I'm reading up on Themes and Master Pages in ASP.NET 2.0 but I cannot seem to understand what the difference between the two are. Do Master Pages essentially end up doing what Themes do? Is...
4
by: Sean | last post by:
My experience now working with master pages on and off for 6 months is that they can be very dangerous when working with themes. One example in particular is the changes I made to my banner menu...
6
by: Clinton Farleigh | last post by:
Hi, I was going to ask a question, but I think I've answered it so now I am going to rant about how crappy ASP.NET themes are instead. As I've indicated above, my problem today is with themes....
3
by: WT | last post by:
Hello, I need to list all available themes for a .NET app, is there any API in ..NET2 for this or should I explore the folder files using IO methods ? Thanks for indication CS
11
by: New Bee | last post by:
Hi, I have been looking at Themes and Skins today and now resonably understand how they work at a ground level. But I have a couple of questions. 1. ) StyleSheetTheme I dont understand...
1
by: Cramer | last post by:
Using 3.5: Suppose I have defined 20+ themes (including multiple graphics, ..skin files, and css files per theme), and I want to make those themes *available* to all the Web sites on my Web server....
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.