# WindowBuilder

## Properties

### WriteAction - Func

## Methods

### Actions(System.Action)

Configures the window buttons.

#### Parameters

##### actionsBuilderAction - System.Action<[WindowActionsBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowactionsbuilder)>

The buttons configuration action.

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .Actions(actions =>
                            actions.Close()
                        )
            )
             
```

### Draggable(System.Action)

Enables (true) or disables (false) the ability for users to move/drag the widget.

#### Parameters

##### configurator - System.Action<[WindowDraggableSettingsBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowdraggablesettingsbuilder)>

The configurator for the draggable setting.

### Draggable(System.Boolean)

Enables (true) or disables (false) the ability for users to move/drag the widget.

#### Parameters

##### enabled - `System.Boolean`

Enables or disables the draggable option.

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .Draggable(true)
            )
             
```

### Animation(System.Action)

Configures the animation effects of the panelbar.

#### Parameters

##### animationAction - System.Action<[PopupAnimationBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/popupanimationbuilder)>

The action that configures the animation.

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .Animation(animation => animation.Close(close => close.Duration(600)))
            )
             
```

### Animation(System.Boolean)

Configures the animation effects of the window.

#### Parameters

##### enable - `System.Boolean`

Whether the component animation is enabled.

#### Example

```
 
            @(Html.Kendo().Window()
                        .Name("Window")
                        .Animation(false)
            )
             
```

### Title(System.Action)

The text in the window title bar. If false, the window will be displayed without a title bar. Note that this will prevent the window from being dragged, and the window titlebar buttons will not be shown.

#### Parameters

##### configurator - System.Action<[WindowTitleSettingsBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowtitlesettingsbuilder)>

The configurator for the title setting.

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                       .Name("Window")
                       .Title(t => t.Text("My Title"))
            )
             
```

### Title(System.Boolean)

Allows title to be shown / hidden

#### Parameters

##### show - `System.Boolean`

Whether the window title will be visible

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                       .Name("Window")
                       .Title(true)
            )
             
```

### Title(System.String)

Sets title, which appears in the header of the window.

#### Parameters

##### title - `System.String`

The title.

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                       .Name("Window")
                       .Title("My title")
            )
             
```

### Modal(System.Action)

Specifies whether the window should show a modal overlay over the page.

#### Parameters

##### configurator - System.Action<[WindowModalSettingsBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowmodalsettingsbuilder)>

The configurator for the modal setting.

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .Modal(m => m.PreventScroll(true))
            )
             
```

### Modal()

Specifies whether the window should show a modal overlay over the page.

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .Modal(m => m.PreventScroll(true))
            )
             
```

### Modal(System.Boolean)

Specifies whether the window should show a modal overlay over the page.

#### Parameters

##### enabled - `System.Boolean`

Enables or disables the modal option.

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .Modal(true)
            )
             
```

### AppendTo(System.String)

Defines a selector for the element to which the Window will be appended. By default this is the page body.

#### Parameters

##### selector - `System.String`

A selector of the Window container

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                       .Name("Window")
                       .AppendTo(".container")
            )
             
```

### Content(System.Action)

Sets the HTML content which the window should display.

#### Parameters

##### value - `System.Action`

The action which renders the content.

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                       .Name("Window")
                       .Content(() =>
                       {
                                <strong>Window content</strong>
                       })
            )
             
```

### Content(System.Func)

Sets the HTML content which the window should display

#### Parameters

##### value - `System.Func<Object,Object>`

The Razor inline template

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                       .Name("Window")
                       .Content(@<strong> Hello World!</strong>))
             
```

### Content(System.String)

Sets the HTML content which the item should display as a string.

#### Parameters

##### value - `System.String`

The action which renders the content.

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .Content("<strong> First Item Content</strong>")
            )
             
```

### Draggable()

Enables (true) or disables (false) the ability for users to move/drag the widget.

### LoadContentFrom(Microsoft.AspNetCore.Routing.RouteValueDictionary)

Sets the Url, which will be requested to return the content.

#### Parameters

##### routeValues - `Microsoft.AspNetCore.Routing.RouteValueDictionary`

The route values of the Action method.

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                    .Name("Window")
                    .LoadContentFrom(MVC.Home.Index().GetRouteValueDictionary());
            )
             
```

### LoadContentFrom(System.String,System.String)

Sets the Url, which will be requested to return the content.

#### Parameters

##### actionName - `System.String`

The action name.

##### controllerName - `System.String`

The controller name.

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .LoadContentFrom("AjaxView_OpenSource", "Window")
            )
             
```

### LoadContentFrom(System.String,System.String,System.Object)

Sets the Url, which will be requested to return the content.

#### Parameters

##### actionName - `System.String`

The action name.

##### controllerName - `System.String`

The controller name.

##### routeValues - `System.Object`

Route values.

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .LoadContentFrom("AjaxView_OpenSource", "Window", new { id = 10})
            )
             
```

### LoadContentFrom(System.String,System.String,Microsoft.AspNetCore.Routing.RouteValueDictionary)

Sets the Url, which will be requested to return the content.

#### Parameters

##### actionName - `System.String`

The action name.

##### controllerName - `System.String`

The controller name.

##### routeValues - `Microsoft.AspNetCore.Routing.RouteValueDictionary`

Route values.

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .LoadContentFrom("AjaxView_OpenSource", "Window", new RouteValueDictionary { { "param1", "1" }, { "param2", "2" } })
            )
             
```

### LoadContentFrom(System.String)

Sets the Url, which will be requested to return the content.

#### Parameters

##### value - `System.String`

The url.

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .LoadContentFrom(Url.Action("AjaxView_OpenSource", "Window"))
            )
             
```

### Resizable()

Enables windows resizing.

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .Resizable()
            )
             
```

### Resizable(System.Action)

Configures the resizing ability of the window.

#### Parameters

##### resizingSettingsAction - System.Action<[WindowResizingSettingsBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowresizingsettingsbuilder)>

Resizing settings action.

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .Resizable(settings =>
                            settings.Enabled(true)
                        )
            )
             
```

### Height(System.Double)

Specifies the height of the Window.

#### Parameters

##### value - `System.Double`

The value for Height

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .Height(500)
            )
             
```

### MaxHeight(System.Double)

The maximum height (in pixels) that may be achieved by resizing the Window.

#### Parameters

##### value - `System.Double`

The value for MaxHeight

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .MaxHeight(500)
            )
             
```

### MaxWidth(System.Double)

The maximum width (in pixels) that may be achieved by resizing the Window.

#### Parameters

##### value - `System.Double`

The value for MaxWidth

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .MaxWidth(500)
            )
             
```

### MinHeight(System.Double)

The minimum height (in pixels) that may be achieved by resizing the Window.

#### Parameters

##### value - `System.Double`

The value for MinHeight

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .MinHeight(200)
            )
             
```

### MinWidth(System.Double)

The minimum width (in pixels) that may be achieved by resizing the Window.

#### Parameters

##### value - `System.Double`

The value for MinWidth

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .MinWidth(400)
            )
             
```

### Width(System.Double)

Specifies the width of the Window.

#### Parameters

##### value - `System.Double`

The value for Width

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .Width(600)
            )
             
```

### Height(System.String)

Specifies the height of the Window.

#### Parameters

##### value - `System.String`

The value for Height

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .Height("500")
            )
             
```

### MaxHeight(System.String)

The maximum height (in pixels) that may be achieved by resizing the Window.

#### Parameters

##### value - `System.String`

The value for MaxHeight

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .MaxHeight("600")
            )
             
```

### MaxWidth(System.String)

The maximum width (in pixels) that may be achieved by resizing the Window.

#### Parameters

##### value - `System.String`

The value for MaxWidth

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .MaxWidth("800")
            )
             
```

### MinHeight(System.String)

The minimum height (in pixels) that may be achieved by resizing the Window.

#### Parameters

##### value - `System.String`

The value for MinHeight

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .MinHeight("300")
            )
             
```

### MinWidth(System.String)

The minimum width (in pixels) that may be achieved by resizing the Window.

#### Parameters

##### value - `System.String`

The value for MinWidth

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .MinWidth("800")
            )
             
```

### Width(System.String)

Specifies the width of the Window.

#### Parameters

##### value - `System.String`

The value for Width

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .Width("600")
            )
             
```

### Position(System.Action)

A collection of one or two members which define the initial top and/or left position of the Window or the position of the containment element on the page.

#### Parameters

##### configurator - System.Action<[WindowPositionSettingsBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowpositionsettingsbuilder)>

The configurator for the position setting.

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
             @(Html.Kendo().Window()
                        .Name("Window")
                        .Position(settings =>
                            settings.Top(100).Left(100)
                        )
            )
             
```

### AutoFocus(System.Boolean)

Determines whether the Window will be focused automatically when opened. The property also influences the focus behavior when an already opened Window is clicked.

#### Parameters

##### value - `System.Boolean`

The value for AutoFocus

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
            @(Html.Kendo().Window()
                .Name("Window")
                .AutoFocus(true)		
            )
             
```

### Iframe(System.Boolean)

Explicitly states whether a content iframe will be created. For more information, refer to the documentation on using iframes.

#### Parameters

##### value - `System.Boolean`

The value for Iframe

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
            @(Html.Kendo().Window()
                .Name("Window")
                .Iframe(true)		
            )
             
```

### Pinned(System.Boolean)

Specifies whether the Window will be pinned, that is, that it will not move together with the page content during scrolling.

#### Parameters

##### value - `System.Boolean`

The value for Pinned

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
            @(Html.Kendo().Window()
                .Name("Window")
                .Pinned(true)		
            )
             
```

### Pinned()

Specifies whether the Window will be pinned, that is, that it will not move together with the page content during scrolling.

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
            @(Html.Kendo().Window()
                .Name("Window")
                .Pinned(true)		
            )
             
```

### Scrollable(System.Boolean)

Enables (true) or disables (false) the scrolling of the Window contents.

#### Parameters

##### value - `System.Boolean`

The value for Scrollable

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
            @(Html.Kendo().Window()
                        .Name("Window")
                        .Scrollable(true)
            )
             
```

### Visible(System.Boolean)

Specifies whether the Window will be initially visible.

#### Parameters

##### value - `System.Boolean`

The value for Visible

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
            @(Html.Kendo().Window()
                        .Name("Window")
                        .Visible(true)
            )
             
```

### Size(System.String)

Sets a predefined size to the Window. The width and height configuration options override the predefined size.The supported values are: auto; small; medium or large.

#### Parameters

##### value - `System.String`

The value for Size

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
            @(Html.Kendo().Window()
                .Name("Window")
                .Size("small")		
            )
             
```

### Events(System.Action)

Configures the client-side events.

#### Parameters

##### configurator - System.Action<[WindowEventBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windoweventbuilder)>

The client events action.

#### RETURNS

Returns the current [WindowBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/windowbuilder) instance.

#### Example

```
 
            @(Html.Kendo().Window()
                  .Name("Window")
                  .Events(events => events
                      .Activate("onActivate")
                  )
            )
             
```

### ToComponent()

Returns the internal view component.

#### RETURNS

The  instance that represents the component.

### Expression(System.String)

Sets the name of the component.

#### Parameters

##### modelExpression - `System.String`

The name.

#### RETURNS

Returns the current  instance.

### Explorer(Microsoft.AspNetCore.Mvc.ViewFeatures.ModelExplorer)

Sets the name of the component.

#### Parameters

##### modelExplorer - `Microsoft.AspNetCore.Mvc.ViewFeatures.ModelExplorer`

The name.

#### RETURNS

Returns the current  instance.

### Name(System.String)

Sets the name of the component.

#### Parameters

##### componentName - `System.String`

The name.

#### RETURNS

Returns the current  instance.

### Deferred(System.Boolean)

Suppress initialization script rendering. Note that this options should be used in conjunction with Kendo.Mvc.UI.Fluent.WidgetFactory.DeferredScripts(System.Boolean,System.Boolean)

#### Parameters

##### deferred - `System.Boolean`

#### RETURNS

Returns a [DeferredWidgetBuilder](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/deferredwidgetbuilder) instance.

### HtmlAttributes(System.Object)

Sets the HTML attributes.

#### Parameters

##### attributes - `System.Object`

The HTML attributes.

#### RETURNS

Returns the current  instance.

### HtmlAttributes(System.Collections.Generic.IDictionary)

Sets the HTML attributes.

#### Parameters

##### attributes - `System.Collections.Generic.IDictionary<String,Object>`

The HTML attributes.

#### RETURNS

Returns the current  instance.

### ScriptAttributes(System.Object,System.Boolean)

Sets the JavaScript attributes to the initialization script.

#### Parameters

##### attributes - `System.Object`

The JavaScript attributes.

##### overrideAttributes - `System.Boolean`

Argument which determines whether attributes should be overriden.

#### RETURNS

Returns the current  instance.

### ScriptAttributes(System.Collections.Generic.IDictionary,System.Boolean)

Sets the JavaScript attributes to the initialization script.

#### Parameters

##### attributes - `System.Collections.Generic.IDictionary<String,Object>`

The JavaScript attributes.

##### overrideAttributes - `System.Boolean`

Argument which determines whether attributes should be overriden.

#### RETURNS

Returns the current  instance.

### Render()

Renders the component in place.

### ToHtmlString()

Returns the HTML representation of the component.

### WriteTo(System.IO.TextWriter,System.Text.Encodings.Web.HtmlEncoder)

#### Parameters

##### writer - `System.IO.TextWriter`

##### encoder - `System.Text.Encodings.Web.HtmlEncoder`

### ToClientTemplate()

Returns the client template for the component.

### AsModule(System.Boolean)

Specifies whether the initialization script of the component will be rendered as a JavaScript module.

#### Parameters

##### value - `System.Boolean`

#### RETURNS

Returns the current  instance.
