Java Script Example
Previous  Top 

Here is an example using Java script to make Call Soft dial a number from your Internet browser.  
 
<%@LANGUAGE="VBSCRIPT" CODEPAGE="1252"%>  
<html>  
<head>  
<title>Untitled Document</title>  
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">  
</head>  
 
<body>  
 
<p>  
<script Language="JavaScript">  
<!--  
function DoDial(number)  
{  
var CallSoftInterface = null;  
 
CallSoftInterface = new ActiveXObject("CallsoftX.CallSoft");  
 
if(CallSoftInterface)  
   {      
   CallSoftInterface.COMConnected = true;  
   CallSoftInterface.Dial(number);  
   }  
}  
function DoHangup()  
{  
var CallSoftInterface = null;  
 
CallSoftInterface = new ActiveXObject("CallsoftX.CallSoft");  
 
if(CallSoftInterface)  
   {      
   CallSoftInterface.COMConnected = true;  
CallSoftInterface.Hangup();  
   }  
}  
 
</script>  
</p>  
<p>Enter the number to dial in the space below then click the Dial button.</p>  
<FORM NAME=form1>  
<input type="text" name="NumberToDial">  
<input type='button' name='myButton' value='Dial'  
onClick="DoDial(this.form.NumberToDial.value)">  
<input type='button' name='myHanupButton' value='Hangup'  
onClick="DoHangup()">  
</FORM>  
</body>  
</html>