%%PageItemTitle%%

VectorDraw Web Library

JsPropertiesExtractor Send comments on this topic.
CmdSelect Method
See Also  Example
vdWebLibrary Namespace > vdrawObj Class : CmdSelect Method
scriptCallBack
A delegate to be fired when the selection finish
Prompts the user to select objets and when finish passed throw the scriptCallBack delegate

Syntax

JScript 
public function CmdSelect( 
   scriptCallBack : Object
);

Parameters

scriptCallBack
A delegate to be fired when the selection finish

Example

C#Copy Code
var vdcanvas = vdmanager.vdrawObject(canvasId); 
vdcanvas.CmdSelect(_cmdselectCallback); 
function _cmdselectCallback(action) { 
    //enum all selected entities 
    if (!action.customData || action.customData.length == 0) return; 
    for (var k = 0; k < action.customData.length; k++) { 
        var fig = action.customData[k]; 
        fig.HighLight = true;//highlight all the selected entities 
    } 
    action.vdrawOwner().redraw(); 
}

Remarks

See Also