Click here to Skip to main content
15,888,320 members
Home / Discussions / ASP.NET
   

ASP.NET

 
GeneralRe: Asynchronous callback with update panel Pin
Ali Al Omairi(Abu AlHassan)5-Feb-11 8:27
professionalAli Al Omairi(Abu AlHassan)5-Feb-11 8:27 
AnswerRe: Asynchronous callback with update panel Pin
Sandeep Mewara4-Feb-11 6:26
mveSandeep Mewara4-Feb-11 6:26 
GeneralRe: Asynchronous callback with update panel Pin
Ali Al Omairi(Abu AlHassan)4-Feb-11 7:16
professionalAli Al Omairi(Abu AlHassan)4-Feb-11 7:16 
Questionsmtp weak server Pin
devboycpp2-Feb-11 3:11
devboycpp2-Feb-11 3:11 
AnswerRe: smtp weak server Pin
Richard MacCutchan3-Feb-11 22:20
mveRichard MacCutchan3-Feb-11 22:20 
QuestionHow to change Theme Pin
Anubhava Dimri2-Feb-11 1:32
Anubhava Dimri2-Feb-11 1:32 
AnswerRe: How to change Theme Pin
Prerak Patel2-Feb-11 2:48
professionalPrerak Patel2-Feb-11 2:48 
GeneralRe: How to change Theme Pin
Shujaat Gul3-Feb-11 19:02
Shujaat Gul3-Feb-11 19:02 
The Best approach is that create BasePage class under the app_code classes and inherit from Page class. Override Page_Preinit and change the theme here. After that Each webform should be inherited from basepage. I am assuming that you have themes under App_Theme Folder. code should be like this:-->

public class BasePage:System.Web.UI.Page
{

protected override void OnPreInit(EventArgs e)
{
base.OnPreInit(e);
string selectedTheme="";
selectedTheme = ThemeManager.GetThemes()[0].Name; /*set top theme as default or from db according to user settings*/

if(!String.isNullorEmpty(selectedTheme))
Page.Theme = selectedTheme;
}
}
public class ThemeManager
{
public ThemeManager()
{

}
#region Theme-Related Method
public static List<Theme> GetThemes()
{
DirectoryInfo dInfo = new DirectoryInfo(System.Web.HttpContext.Current.Server.MapPath("~/App_Themes"));
DirectoryInfo[] dArrInfo = dInfo.GetDirectories();
List<Theme> list = new List<Theme>();
foreach (DirectoryInfo sDirectory in dArrInfo)
{
Theme temp = new Theme(sDirectory.Name);
list.Add(temp);
}
return list;
}
#endregion


}
AnswerRe: How to change Theme Pin
Sandeep Mewara4-Feb-11 6:24
mveSandeep Mewara4-Feb-11 6:24 
Questionsql query Pin
C#Coudou1-Feb-11 13:26
C#Coudou1-Feb-11 13:26 
AnswerRe: sql query Pin
s_magus1-Feb-11 16:10
s_magus1-Feb-11 16:10 
GeneralRe: sql query Pin
C#Coudou1-Feb-11 18:54
C#Coudou1-Feb-11 18:54 
GeneralRe: sql query Pin
Brij1-Feb-11 20:33
mentorBrij1-Feb-11 20:33 
QuestionHow i can set IDENTITY_INSERT to ON in "LINQ to SQL" ? Pin
humais1-Feb-11 8:21
humais1-Feb-11 8:21 
AnswerRe: How i can set IDENTITY_INSERT to ON in "LINQ to SQL" ? Pin
TheGreatAndPowerfulOz1-Feb-11 12:32
TheGreatAndPowerfulOz1-Feb-11 12:32 
QuestionRe: How i can set IDENTITY_INSERT to ON in "LINQ to SQL" ? Pin
Ali Al Omairi(Abu AlHassan)5-Feb-11 8:36
professionalAli Al Omairi(Abu AlHassan)5-Feb-11 8:36 
AnswerRe: How i can set IDENTITY_INSERT to ON in "LINQ to SQL" ? Pin
Vika Dev1-Feb-11 16:43
Vika Dev1-Feb-11 16:43 
GeneralRe: How i can set IDENTITY_INSERT to ON in "LINQ to SQL" ? Pin
humais2-Feb-11 3:17
humais2-Feb-11 3:17 
AnswerRe: How i can set IDENTITY_INSERT to ON in "LINQ to SQL" ? Pin
Bryian Tan1-Feb-11 17:07
professionalBryian Tan1-Feb-11 17:07 
Questioncalendar access Pin
netJP12L1-Feb-11 7:28
netJP12L1-Feb-11 7:28 
AnswerRe: calendar access Pin
Not Active1-Feb-11 7:41
mentorNot Active1-Feb-11 7:41 
QuestionASP .net exception Pin
Pmandale1-Feb-11 0:11
Pmandale1-Feb-11 0:11 
AnswerRe: ASP .net exception Pin
m@dhu1-Feb-11 1:33
m@dhu1-Feb-11 1:33 
QuestionAfter loging open the file for user connnected [modified] Pin
amina8931-Jan-11 23:33
amina8931-Jan-11 23:33 
QuestionRe: After loging open the file for user connnected Pin
amina892-Feb-11 0:27
amina892-Feb-11 0:27 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.