WebApplication.PreferredApplicationWindowTemplateType Property

Specifies the Template type for the application's main page.

Namespace: DevExpress.ExpressApp.Web

Assembly: DevExpress.ExpressApp.Web.v18.1.dll

Syntax

public static TemplateType PreferredApplicationWindowTemplateType { get; set; }

Returns

Type Description
TemplateType

A TemplateType enumeration value that specifies the Template type for the application's main page. The default is TemplateType.Vertical.

To use the Default Template for the main window instead of DefaultVertical, set the PreferredApplicationWindowTemplateType property to TemplateType.Horizontal in the ASP.NET application's Session_Start event handler (you can find this handler code in the Global.asax.cs (Global.asax.vb) file).

using DevExpress.ExpressApp.Web.Templates;
// ... 
protected void Session_Start(Object sender, EventArgs e) {
    WebApplication.SetInstance(Session, new MySolutionAspNetApplication());
    // ... 
    WebApplication.PreferredApplicationWindowTemplateType = TemplateType.Horizontal;
}
Note

The PreferredApplicationWindowTemplateType property should be initialized after the WebApplication.SetInstance method is called. Otherwise, the "Cannot change the ValueManager.ValueManagerType property after it's initialized" error may occur.