ComponentOne ASP.NET MVC Controls
SplitLayout Class
Members  Example 

C1.Web.Mvc Namespace : SplitLayout Class
Defines a class represents the split layout.
Syntax
'Declaration
 
Public Class SplitLayout 
   Inherits LayoutBase
   Implements ITemplate 
public class SplitLayout : LayoutBase, ITemplate  
Remarks

The SplitLayout class is used to define the SplitLayout for the DashboardLayout control, which enables to position the tiles with multiple orientations.The following options for the layout can be set using the properties of this class:

1. The layout orientation can be set to horizontal or vertical using the Orientation property.

2. The groups which are of type SplitGroup class, are added using the AddGroup method of the SplitLayoutItemFactoryBuilder class and can be retrieved using the Items property of this class.

Example
@(Html.C1().DashboardLayout()
    .AttachSplitLayout(slb => slb.Orientation(LayoutOrientation.Horizontal)
        .Items(isb =>
        {
            isb.AddGroup()
                .Size("2*")
                .Orientation(LayoutOrientation.Vertical)
                .Children(vgcb =>
                {
                    vgcb.AddGroup()
                        .Size("*")
                        .Orientation(LayoutOrientation.Horizontal)
                        .Children(hgcb =>
                        {
                            hgcb.AddTile()
                        .Size("*")
                        .HeaderText("Products Stock")
                        .Content("#ProductsStock");                         
                        });
                    vgcb.AddTile()
                        .Size("*")
                        .HeaderText("Product Details")
                        .Content("#ProductDetails");
                });

            isb.AddGroup()
                .Size("*")
                .Orientation(LayoutOrientation.Vertical)
                .Children(hgcb =>
                {
                    hgcb.AddTile()
                                    .Size("*")
                                    .HeaderText("CategorySales")
                                    .Content("#CategorySales");                  
                });
        }))
)
Inheritance Hierarchy

System.Object
   C1.Web.Mvc.Component
         C1.Web.Mvc.LayoutBase
            C1.Web.Mvc.SplitLayout

See Also

Reference

SplitLayout Members
C1.Web.Mvc Namespace