Skip to main content

MVCxClientListBox.Cast(obj) Method

Converts the specified object to the MVCxClientListBox type.

#Declaration

TypeScript
static Cast(
    obj: any
): MVCxClientListBox

#Parameters

Name Type Description
obj any

The client object to be type cast.

#Returns

Type Description
MVCxClientListBox

The converted client object specified by the obj parameter.

#Remarks

Call the static Cast method to cast the specified client object to the MVCxClientListBox type. As a result, the type specific IntelliSense information can be displayed for the object.

#Example

Convert the event source object passed to a client event’s handler.

<ClientSideEvents Init="function(s, e) { 
     var clientObject = MVCxClientListBox.Cast(s);
}" /> 

Convert a client object accessed by its ListBoxSettings.Name property value.

@Html.DevExpress().ListBox(
     settings => {
          settings.Name = "MVCxClientListBox1";
...
var clientObject = MVCxClientListBox.Cast('MVCxClientListBox1'); 
See Also