ASP Dialer Form

rcm3075

Newcomer
Joined
Nov 10, 2003
Messages
1
Hi Im trying to create a form that can dial phone numbers using this asp code but i keep receiving erros can somebody email me some help rcm3075@prtc.net

<%@LANGUAGE="VBSCRIPT" CODEPAGE="1252"%>



<% Dial_Click()

Dim strDialStr As String
Dim ctlPrevCtl As Control
Const ERR_OBJNOTEXIST = 2467
Const ERR_OBJNOTSET = 91

DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, , acMenuVer70

Set ctlPrevCtl = Screen.PreviousControl

If TypeOf ctlPrevCtl Is TextBox Then
strDialStr = IIf(VarType(ctlPrevCtl) > V_NULL, ctlPrevCtl, "")
ElseIf TypeOf ctlPrevCtl Is ListBox Then
strDialStr = IIf(VarType(ctlPrevCtl) > V_NULL, ctlPrevCtl, "")
ElseIf TypeOf ctlPrevCtl Is ComboBox Then
strDialStr = IIf(VarType(ctlPrevCtl) > V_NULL, ctlPrevCtl, "")
Else
strDialStr = ""
End If
%>
<%
Application.Run "utility.wlib_AutoDial", strDialStr

Exit_Dial_Click:
Exit Sub

Err_Dial_Click:
If (Err = ERR_OBJNOTEXIST) Or (Err = ERR_OBJNOTSET) Then
Resume Next
End If
%>
<%
MsgBox Err.Description
Resume Exit_Dial_Click
End Sub
%>
<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>

<body>
<form name="form1" method="post" action="default.asp">
<input name="strDialStr" type="text" id="strDialStr2">
<input name="Dial" type="submit" id="Dial" value="Dial">
</form>
</body>
</html>
<%
strDialStr As String
Set strDialStr = Nothing
%>
 
Back
Top