SP.ClientRuntimeContext.castTo(obj, type) Method
Applies to: SharePoint Foundation 2010
In this article
Return Value
Applies To
Remarks
Casts a specified client object to its derived type.
var value = SP.ClientRuntimeContext.castTo(obj, type);
Parameters
- obj
The SP.ClientObject Class object that represents the client object to be cast to its derived type.
Type: SP.ClientObject
- type
The object that represents the derived type of the provided client object.
Type: Type
Return Value
Type: SP.ClientObject
Applies To
Remarks
This method casts the specified client object only to its derived client object; therefore, the destination object must also inherit from the SP.ClientObject Class.
See Also
Reference
SP.ClientRuntimeContext Methods