?
Solved

Get list of available themes in App_Themes folder

Posted on 2008-10-27
1
Medium Priority
?
376 Views
Last Modified: 2013-12-17
Hello,

Is there a simple way to get a list of the top-level folders in the App_Themes folder in my .NET website?  Is the simplest way to just use the Directory class to list the directories or is there some collection of themes somewhere that I can access?

Basically, I need to make a dropdown of all the themes in the website.

Thanks!
0
Comment
Question by:sushik15
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 6

Accepted Solution

by:
AmarIs26 earned 1600 total points
ID: 22817557
The way i use is to use the Directory class to get a list of directories. As far as i know it is a reasonable way and beside you as a developer should not be putting anything in App_Themes folder which does not belong there. So its reasonsable to assume that all directories in the themes folder will be themes.
Also its best to get the list of themes and then stick the list in cache to avoid having to use the directory or directoryinfo classes.
0

Featured Post

Veeam Disaster Recovery in Microsoft Azure

Veeam PN for Microsoft Azure is a FREE solution designed to simplify and automate the setup of a DR site in Microsoft Azure using lightweight software-defined networking. It reduces the complexity of VPN deployments and is designed for businesses of ALL sizes.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Many of us here at EE write code. Many of us write exceptional code; just as many of us write exception-prone code. As we all should know, exceptions are a mechanism for handling errors which are typically out of our control. From database errors, t…
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…
Suggested Courses

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question