Feedback

  • Contents
 

scripter.createCallObject Method

Definition

This method creates a new CallObject.  You must first create a call object before dialing a number, or setting up a consult transfer, or conference. 

Prototype

scripter.createCallObject([out,retval] CallObject)

Syntax

myObj=scripter.createCallObject();

Input Parameters

None.

Return Values

CallObject

The new CallObject that was created.


Example

<html>
<head>
    <title>Scripter Object</title>
    <script type="text/JavaScript">
        function MakeCall() { var CallObject = scripter.createCallObject(); CallObject.Dial(Phonenumber.value, false); }

 
      function createCallObject() {

     callObj = scripter.createCallObject();

     callObj.callObjectInitializedHandler = initializedCallback;

     // Set the ID, which begins the initialization

     callObj.id = IS_Attr_CallID.value;

}

function initializedCallback() {

     scripter.trace("Remote ID: " + callobj.remoteId);

}     </script> </head>
<body>     <table>         <tr>             <td><input type=button onclick="MakeCall();" value="Dial"></td>             <td>Phone Number<input name="Phonenumber" id="Phonenumber"></td>         </tr>     </table> </body> </html>