VoiceGuide IVR Software Main Page
Jump to content

Unable To Log Data.(logging Problem0

Recommended Posts

Hi

 

I am trying to write the following data i.e., LineID,CallerID etc., and few more data to the log trace.

I viewed all the the log files but unable to get the data in trace file/log file.

This is the script which i am using as the start module.

I have also add the vgs file to the .

 

 

sThisScript = "leave msg.vgs"

sThisModule = "LmRecInit"

 

function ldgz(ByVal N) ' N presumed integer

if (N>=0) and (N<10) then ldgz= "0"+Cstr(N) else ldgz=Cstr(N)

end function

 

Yr = Year(Now) : Mo = ldgz(Month(Now)) : Dy = ldgz(Day(Now))

Hr = ldgz(Hour(Now)) : Mi = ldgz(Minute(Now)) : Sc = ldgz(Second(Now))

sDateTimeStamp = Mo & Dy & Hr & Mi & Sc

 

'above is the alternate way of getting a Timestamp rather the using VGs Result Variables.

 

iLineId = $RV_LINEID

 

sFname = "$RV[TheOtherLoginID]_$RV[LoginID]_" & sDateTimeStamp & "_1_" & iLineId & "_.wav"

 

Set vg = CreateObject("VoiceGuide.CommandLink")

 

vg.Admin_TraceLogAdd 0, 0, "APMIP Data before RV_DEVICEID"

iDeviceId = $RV_DEVICEID

 

vg.Admin_TraceLogAdd 0, 0, "APMIP Data before RV_CIDNUMBER"

iCallerID = $RV_CIDNUMBER

 

'iLineId = $RV_LINEID

 

vg.Admin_TraceLogAdd 0, 0, "APMIP Data before RV_STARTTIME"

iStartTime = $RV_STARTTIME

 

vg.Admin_TraceLogAdd 0, 0, "APMIP Data"

vg.Admin_TraceLogAdd iLineId, 0, "APMIP Data"

vg.Admin_TraceLogAdd iLineId, 0, iStartTime

vg.Admin_TraceLogAdd iLineId, 0, iDeviceId

vg.Admin_TraceLogAdd iLineId, 0, iCallerID

vg.Admin_TraceLogAdd iLineId, 0, iLineId

 

 

sNewRv = "[LmRecFilename]{" & sFname & "}"

sRet = vg.Run_ResultReturn(iLineId, sNewRv)

Set vg = Nothing

 

 

I am also attaching the trace file and vgs file. I am unable to get these details in Trace

 

 

What my task is wen I recive the call I have to run a script and

in which I have to create a folder with the callerID and dstarttime combination,

after the script i will be asking few question to the caller and record the responses and save these files into this folder.

At the end I have to save this callerId and call time/starttime and folder location into MySql Database.

 

please help me.

1024_1910_vgEngine.txt

1024_1913_vgEngine.txt

leave_msg.vgs

Share this post


Link to post

Some of the modifications you made to the script may stop it from running. You should add Admin_TraceLogAdd calls from the beginning of the VBScript and track the scripts progress to see if it stops executing at some stage due to error in script.

 

Share this post


Link to post

Hi

I have modified the script as below.

even now i could not get the first line into the log/trace.

 

 

set vg = CreateObject("vgServices.CommandLink")

vg.Admin_TraceLogAdd 0, 0, "APMIP Data start"

 

sThisScript = "leave msg.vgs"

sThisModule = "LmRecInit"

 

function ldgz(ByVal N) ' N presumed integer

if (N>=0) and (N<10) then ldgz= "0"+Cstr(N) else ldgz=Cstr(N)

end function

 

Yr = Year(Now) : Mo = ldgz(Month(Now)) : Dy = ldgz(Day(Now))

Hr = ldgz(Hour(Now)) : Mi = ldgz(Minute(Now)) : Sc = ldgz(Second(Now))

sDateTimeStamp = Mo & Dy & Hr & Mi & Sc

 

'above is the alternate way of getting a Timestamp rather the using VGs Result Variables.

 

iLineId = $RV_LINEID

 

sFname = "$RV[TheOtherLoginID]_$RV[LoginID]_" & sDateTimeStamp & "_1_" & iLineId & "_.wav"

 

'Set vg = CreateObject("vgServices.CommandLink")

 

vg.Admin_TraceLogAdd 0, 0, "APMIP Data before RV_DEVICEID"

iDeviceId = $RV_DEVICEID

 

vg.Admin_TraceLogAdd 0, 0, "APMIP Data before RV_CIDNUMBER"

iCallerID = $RV_CIDNUMBER

 

'iLineId = $RV_LINEID

 

vg.Admin_TraceLogAdd 0, 0, "APMIP Data before RV_STARTTIME"

iStartTime = $RV_STARTTIME

 

vg.Admin_TraceLogAdd 0, 0, "APMIP Data"

vg.Admin_TraceLogAdd iLineId, 0, "APMIP Data"

vg.Admin_TraceLogAdd iLineId, 0, iStartTime

vg.Admin_TraceLogAdd iLineId, 0, iDeviceId

vg.Admin_TraceLogAdd iLineId, 0, iCallerID

vg.Admin_TraceLogAdd iLineId, 0, iLineId

 

 

sNewRv = "[LmRecFilename]{" & sFname & "}"

sRet = vg.Run_ResultReturn(iLineId, sNewRv)

Set vg = Nothing

 

I am also attaching the vgs and the tracefile.

I have the following setting in vg.ini

 

[Log]

;Automated "log-to-file" logging.

;To turn OFF logging for a particular application set it's entry to 0

;To turn ON all logging for a particular application set it's entry to 10

;all log files are saved in VoiceGuide's \log\ subdirectory

 

;Log files are named as follows:

;VoiceGuide : MMDD_HHNN_vgEngine.txt

;ktTel : MMDD_ktTel.txt

;ktTts : MMDD_ktTts.txt

 

VoiceGuide=10

NumberLoader=0

ktTel=10

ktTts=0

 

;uncomment below to stop any Script-relates logs (*.vgl/*.csv/*.xml)

;from being created as each script is executed.

;Scripts=OFF

 

;set CDR_LastData_SaveRv to 1 to save in the CDR record the RVs created during the call

CDR_LastData_SaveRv=0

1027_1119_vgEngine.txt

leave_msg.vgs

Share this post


Link to post

I don’t think the VBScript you quoted is a valid VBScript.

 

To check what VBScript is ran by VoiceGuide you can lookup the filename in the vgEngine trace.

 

The trace supplied shows that the VBScript was saved in C:\Program Files\VoiceGuide\temp\vbs_7_1.vbs and was ran from there.

 

Suggest you just double-click on the C:\Program Files\VoiceGuide\temp\vbs_7_1.vbs file (you can do this while VoiceGuide is running) and see if any error messages get displayed. If there is an error you will be told on what line the error occurred.

 

If you have problems with VBScripts then the best way to approach them is to start with a simple VBScript, confirm that it works and then add to it bit by bit confirming that it works after each addition.

 

eg. start with just this:

 

set vg = CreateObject("vgServices.CommandLink")

vg.Admin_TraceLogAdd 0, 0, "This trace was printed from an external VB Script"

set vg = Nothing

 

 

 

112013.437 18 7 state [LmRecInit] type: VB Script, iRunWait=2

112013.468 18 7 rv replace start (strlen>500)

112013.468 18 7 rvns: [PathSysVoice]{}[PathApp]{C:\Program Files\VoiceGuide\}[PathDataVm]{C:\Program Files\VoiceGuide\data\}[PathVgSys]{C:\Program Files\VoiceGuide\system\}[scriptPath]{C:\Chatline\scripts\}[scriptsPath]{C:\Chatline\scripts\}[$RV_STARTTIME]{2008-10-27 11:20:13}[$RV_DEVICEID]{7}[DlgcVoice]{dxxxB1C4}[DlgcNetwork]{dxxxB1C4}[PathApp]{C:\Program Files\VoiceGuide\}[scriptsPath]{C:\Chatline\scripts\}

112013.468 18 7 script will be ran from file: C:\Program Files\VoiceGuide\temp\vbs_7_1.vbs

112013.468 18 7 delete existing: C:\Program Files\VoiceGuide\temp\vbs_7_1.vbs

112013.500 18 7 current objVbsOrExeProcess=

112013.500 18 7 RunVBScriptFile [wscript][C:\Program Files\VoiceGuide\temp\vbs_7_1.vbs][] timeout=60 (vbsPath=C:\Program Files\VoiceGuide\temp), start (new Process)

112013.500 18 7 objVbsOrExeProcess.Start call

112013.625 18 7 RunVBScriptFile just started. Handle=34016, Id=5788, StartTime=10/27/2008 11:20:13 AM, HasExited=False

112013.625 18 7 VBScript started [C:\Program Files\VoiceGuide\temp\vbs_7_1.vbs], ProcessHandle=[34016], VbsOrExeProcess.WorkingSet=[90112]

Share this post


Link to post

Hi

 

Thanks Now i can trace the data.

 

I opened the file and ran directly , i got few error and i modified them and the problem resolved, indeed waht you said was correct there were error in the script,

C:\Program Files\VoiceGuide\temp\vbs_7_1.vbs

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×