I have been using the script below to capture in-use vectors on an Avaya switch to a blank capture file, which I then copy as a spreadsheet and use for easy searching of ROUTE TO numbers and MESSAGING split extensions, etc.
I am wondering if there is a better way to capture the data to automatically eliminate the excessive blank lines and empty vector steps.
proc main
string sLine
string vector1
fopen 0 "c:\vector.csv" READ TEXT
while not feof 0
fgets 0 sLine
strtok vector1 sLine "," 1
pause 1
transmit "disp vect "
pause 1
transmit vector1 ;vector1 is read from file vector.csv
pause 1
capture on
pause 1
transmit "^M" ;pressing ENTER to execute DISP VECT command
pause 1
capture off ;allows the current screen data to remain in the capture file
pause 1
capture on
pause 1
transmit "^[OV" ;pressing F7 for NEXT PAGE
pause 1
capture off
pause 1
capture on
pause 1
transmit "^[OV" ;pressing F7 for NEXT PAGE
pause 1
capture off
pause 1
transmit "^[OP" ;pressing F1 to exit to command line
pause 2
endwhile
fclose 0
endproc
Any suggestions would be appreciated!
I am wondering if there is a better way to capture the data to automatically eliminate the excessive blank lines and empty vector steps.
proc main
string sLine
string vector1
fopen 0 "c:\vector.csv" READ TEXT
while not feof 0
fgets 0 sLine
strtok vector1 sLine "," 1
pause 1
transmit "disp vect "
pause 1
transmit vector1 ;vector1 is read from file vector.csv
pause 1
capture on
pause 1
transmit "^M" ;pressing ENTER to execute DISP VECT command
pause 1
capture off ;allows the current screen data to remain in the capture file
pause 1
capture on
pause 1
transmit "^[OV" ;pressing F7 for NEXT PAGE
pause 1
capture off
pause 1
capture on
pause 1
transmit "^[OV" ;pressing F7 for NEXT PAGE
pause 1
capture off
pause 1
transmit "^[OP" ;pressing F1 to exit to command line
pause 2
endwhile
fclose 0
endproc
Any suggestions would be appreciated!