cjdevconpro Report post Posted 03/25/2005 07:38 PM This application is a small form that pops on the server side when a call comes in from a VG Script. Just copy and paste the following the code into a new VB.NET solution: Public Class Form1 Inherits System.Windows.Forms.Form #Region " Windows Form Designer generated code " Public Sub New() MyBase.New() 'This call is required by the Windows Form Designer. InitializeComponent() 'Add any initialization after the InitializeComponent() call End Sub 'Form overrides dispose to clean up the component list. Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean) If disposing Then If Not (components Is Nothing) Then components.Dispose() End If End If MyBase.Dispose(disposing) End Sub 'Required by the Windows Form Designer Private components As System.ComponentModel.IContainer 'NOTE: The following procedure is required by the Windows Form Designer 'It can be modified using the Windows Form Designer. 'Do not modify it using the code editor. Friend WithEvents TextBox1 As System.Windows.Forms.TextBox Friend WithEvents Label1 As System.Windows.Forms.Label Friend WithEvents Label2 As System.Windows.Forms.Label Friend WithEvents TextBox2 As System.Windows.Forms.TextBox Friend WithEvents Label3 As System.Windows.Forms.Label Friend WithEvents TextBox3 As System.Windows.Forms.TextBox Friend WithEvents Label4 As System.Windows.Forms.Label Friend WithEvents TextBox4 As System.Windows.Forms.TextBox <System.Diagnostics.DebuggerStepThrough()> Private Sub InitializeComponent() Me.TextBox1 = New System.Windows.Forms.TextBox Me.Label1 = New System.Windows.Forms.Label Me.Label2 = New System.Windows.Forms.Label Me.TextBox2 = New System.Windows.Forms.TextBox Me.Label3 = New System.Windows.Forms.Label Me.TextBox3 = New System.Windows.Forms.TextBox Me.Label4 = New System.Windows.Forms.Label Me.TextBox4 = New System.Windows.Forms.TextBox Me.SuspendLayout() ' 'TextBox1 ' Me.TextBox1.Location = New System.Drawing.Point(16, 32) Me.TextBox1.Name = "TextBox1" Me.TextBox1.Size = New System.Drawing.Size(328, 20) Me.TextBox1.TabIndex = 0 Me.TextBox1.Text = "" ' 'Label1 ' Me.Label1.Location = New System.Drawing.Point(16, 16) Me.Label1.Name = "Label1" Me.Label1.TabIndex = 1 Me.Label1.Text = "Extension dialed :" ' 'Label2 ' Me.Label2.Location = New System.Drawing.Point(16, 80) Me.Label2.Name = "Label2" Me.Label2.TabIndex = 2 Me.Label2.Text = "Line ID" ' 'TextBox2 ' Me.TextBox2.Location = New System.Drawing.Point(16, 96) Me.TextBox2.Name = "TextBox2" Me.TextBox2.Size = New System.Drawing.Size(328, 20) Me.TextBox2.TabIndex = 3 Me.TextBox2.Text = "" ' 'Label3 ' Me.Label3.Location = New System.Drawing.Point(16, 144) Me.Label3.Name = "Label3" Me.Label3.TabIndex = 4 Me.Label3.Text = "Caller ID" ' 'TextBox3 ' Me.TextBox3.Location = New System.Drawing.Point(16, 160) Me.TextBox3.Name = "TextBox3" Me.TextBox3.Size = New System.Drawing.Size(328, 20) Me.TextBox3.TabIndex = 5 Me.TextBox3.Text = "" ' 'Label4 ' Me.Label4.Location = New System.Drawing.Point(16, 208) Me.Label4.Name = "Label4" Me.Label4.TabIndex = 6 Me.Label4.Text = "Caller Name" ' 'TextBox4 ' Me.TextBox4.Location = New System.Drawing.Point(16, 224) Me.TextBox4.Name = "TextBox4" Me.TextBox4.Size = New System.Drawing.Size(328, 20) Me.TextBox4.TabIndex = 7 Me.TextBox4.Text = "" ' 'Form1 ' Me.AutoScaleBaseSize = New System.Drawing.Size(5, 13) Me.ClientSize = New System.Drawing.Size(360, 278) Me.Controls.Add(Me.TextBox4) Me.Controls.Add(Me.Label4) Me.Controls.Add(Me.TextBox3) Me.Controls.Add(Me.Label3) Me.Controls.Add(Me.TextBox2) Me.Controls.Add(Me.Label2) Me.Controls.Add(Me.TextBox1) Me.Controls.Add(Me.Label1) Me.Name = "Form1" Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen Me.Text = "Form1" Me.ResumeLayout(False) End Sub #End Region Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load 'Call the function to capture the digits CallArgs() End Sub Private Sub CallArgs() Dim Args() As String = Environment.GetCommandLineArgs If Args.GetUpperBound(0) > 0 Then 'remember to test the size of the array TextBox1.Text = Args(1) TextBox2.Text = Args(2) If Args(3) = "" Then TextBox3.Text = "UNKNOWN CALLER" Else TextBox3.Text = Args(3) End If If Args(4) = "" Then TextBox4.Text = "UNKNOWN CALLER" Else TextBox4.Text = Args(4) End If End If End Sub End Class Now, to get the VG to pop it, do the following: Use the attached VGS file. Record a wav to prompt the extension to be dialed. And test from there. Just a little something to help out. Cheers!! Share this post Link to post
SupportTeam Report post Posted 03/25/2005 10:28 PM Now, to get the VG to pop it, do the following: Use the attached VGS file. No .VGS file was attached... any chance you could try attaching it again? Share this post Link to post
cjdevconpro Report post Posted 03/25/2005 10:32 PM Oops, sorry about that. In the attached ZIP file is the Recordings that I made for the modules. GetAndtransfer.zip Share this post Link to post