CodeVerge.Net Beta
Login Idy
Register Password
  Forgot?
Explore    Item Entry    Members   
NEWSGROUP
.NET
Algorithms-Data Structures
Asp.Net
C Plus Plus
CSharp
Database
HTML
Javascript
Linq
Other
Regular Expressions
VB.Net
XML





Zone: > NEWSGROUP > Asp.Net Forum > general_asp.net.master_pages_themes_and_navigation_controls Tags:
Item Type: NewsGroup Date Entered: 11/3/2005 10:22:32 AM Date Modified: Subscribers: 0 Subscribe Alert
Rate It:
(NR, 0)
XPoints: N/A Replies: 5 Views: 9 Favorited: 0 Favorite
Can Reply:  No Members Can Edit: No Online: Yes
6 Items, 1 Pages 1 |< << Go >> >|
subgurim
Asp.Net User
dinamic themes question11/3/2005 10:22:32 AM

0/0

Hi, I've one question about themes. What I want is to assign a theme to a page programatically (easy), but I want to upload this theme also programatically.

I mean, I want to write a skin file in a text box, submit it and automatically change the theme of this page... is it possible?
subgurim.net: blog de ASP.NET 2.0 con C# en castellano
es-asp.net: el portal de ASP.NET en castellano
Fredrik N
Asp.Net User
Re: dinamic themes question11/3/2005 10:48:31 AM

0/0

It's possible.

To specify a Theme programatically you can use the Page_PreInit event of the page and set the theme. To set the theme for the current page you use the Theme property of the Page class.

Page.Theme = "MyNewThemeName"
/Fredrik Norm?n NSQUARED2
Microsoft MVP, MCSD, MCAD, MCT

Cornerstone

My Blog, ASP.Net 2.0 etc
subgurim
Asp.Net User
Re: dinamic themes question11/3/2005 1:16:13 PM

0/0

thanks fredrik, but I have one more question.

what I want to do is let the users to upload the skin files and automatically apply this theme.

Is it solved if I upload these skin files to a new directory inside the app_themes?

Is there other solution?

I also want to apply themes getting the URL of the skin files with a webservice.

Thanks.
subgurim.net: blog de ASP.NET 2.0 con C# en castellano
es-asp.net: el portal de ASP.NET en castellano
Fredrik N
Asp.Net User
Re: dinamic themes question11/3/2005 2:04:12 PM

0/0

To use a Theme they must be located within the Web app's App_Themes folder.

To create a theme you must create a sub folder to the App_Themes. The name of the folder must have the same name as the .skin file:

App_Themes
      MyTheme
            MyTheme.skin

To specify the theme you want to use, you use the name of the theme folder:

Page.Theme = MyTheme.skin

If the user already has a .skin file and you want them to upload the skin to the server, you can use the new UpLoad control.
/Fredrik Norm?n NSQUARED2
Microsoft MVP, MCSD, MCAD, MCT

Cornerstone

My Blog, ASP.Net 2.0 etc
mischa
Asp.Net User
Re: dinamic themes question11/9/2005 7:59:03 AM

0/0

Hi, I have a question...

can I specify programatically a theme in a MasterPage?
I thnik the PreInit of the MasterPage doesn't fire???

I have about 50 Pages with one Master. Is there a easy way, to serve a function for dynamicly changing the theme?

Fredrik N
Asp.Net User
Re: dinamic themes question11/9/2005 10:20:20 AM

0/0

You can't change the Theme in the MasterPage because is must be done in the PreInti event which the MasterPage don't have.

What you can do is to create your own custom page that inhertis the Page class and set the Theme in your new custom Page class. Make sure all your pages inherits your custom page class instead of the Page class.

You can also set the Theme in the global.asax and that by doing that you don't need to create a custom Page class. Take a look at this post for more information.
/Fredrik Norm?n NSQUARED2
Microsoft MVP, MCSD, MCAD, MCT

Cornerstone

My Blog, ASP.Net 2.0 etc
6 Items, 1 Pages 1 |< << Go >> >|



Search This Site:


Meet Our Sponsors:



Other Resources:

Authenticate to another portal - novell.devsup.exdirector - Web ... Authenticate to another portal, > ROOT > NEWSGROUP > Novell Forums > novell.devsup.exdirector, Date: 2 ... dinamic themes question. how to login as admin role? ...
Windows Mobile 6 support - novell.support.groupwise.7x.wireless - Web ... dinamic property in webpart?? load webpart into zone by its id ... web project system question. themes and cookies. ms access membership provider for asp.net 2.0 ...
Menu Movie & dinamic Text - FlashDen Site Templates & Themes. PSDTUTS. Photoshop Tutorials. VECTORTUTS. Illustrator Tutorials ... AS3 loader question last post by ourben ...
Master Pages, Themes and Navigation Controls - ASP.NET Forums dinamic themes question. by subgurim. Re: dinamic themes... by Fredrik N. 11-09-2005, 5:20 AM. 5. 581 ... Questions / Problems with this site? Visit our hoster: ...
Weeks - Clan Themes Search It - PhpNuke Clan Themes - PhpNuke Themes ... This is a dinamic addon for the QuakeWars center info module. ... Please browse the site and feel free to say hello or ask questions in the Forums. ...
mod rewrite question [Support Forums - XOOPS.org Members Lounge ... ... But I wanted the links (ALL of them) to have a dinamic rewrite rule. ... Re: mod rewrite question #4. Themes Designer. Joined: 2002/1/22 17:46. Posts: 1162 ...
Upgraded - Clan Themes Search It - PhpNuke Clan Themes - PhpNuke Themes ... This is a dinamic addon for the QuakeWars center info module. ... and remember to visit www.creativenuke.com if you have any question or problem. ...
Dinamic Block with Multiple Categories and Subcategories... Its ... ... Core Modules Module Packs Themes. Documentation. Wiki FAQ Demo ... XOOPS general usage questions. Dinamic Block with Multiple Categories and Subcategories...


 
All Times Are GMT