eboughey1008
Programmer
I want the job number which is a variable to update in the .bat file but I've not been able to do it.
I tried to strtofile() but it takes it literally and puts alltrim(listno) instead of the job number. Can I run some type of 'update' command for a text file? I can't find what I'm looking for anywhere.. Hard line text no problem but variable info updating to the file? not easy to find.
CLOSE ALL
CLEAR
SET SAFETY OFF
CLIST_NO = SPACE (15)
@ 11,5 say 'Enter List_no Value for sales import: ' get CLIST_NO
READ
CLEAR
**** DOES A BUNCH OF STUFF ******
listno = LEFT(CLIST_NO,5)
*** COPIES THE FILE TO BE UPLOADED FOR NCOA ***
COPY fields record_id, first, last, address, address2, city, state, zip to ALLTRIM(lcJobDir)+"NCOA-"+alltrim(listno)+".csv" DELIMITED WITH "" with CHARACTER tab
*** GOES TO THAT DIRECTORY ***
cExport="e:\working\ncoa\incoming"
SET DEFAULT TO "&cExport"
**************PROBLEM COMMAND ******************** (had to use single quotes around command)
STRTOFILE('e:\working\ncoa\incoming\truencoa.exe "E:\working\ncoa\incoming\NCOA-"+ALLTRIM(LISTNO)+".csv" "username" "pass" " true"','e:\working\ncoa\incoming\truencoa.bat')
Can anyone help with this? probably an easy fix....
Elena
I tried to strtofile() but it takes it literally and puts alltrim(listno) instead of the job number. Can I run some type of 'update' command for a text file? I can't find what I'm looking for anywhere.. Hard line text no problem but variable info updating to the file? not easy to find.
CLOSE ALL
CLEAR
SET SAFETY OFF
CLIST_NO = SPACE (15)
@ 11,5 say 'Enter List_no Value for sales import: ' get CLIST_NO
READ
CLEAR
**** DOES A BUNCH OF STUFF ******
listno = LEFT(CLIST_NO,5)
*** COPIES THE FILE TO BE UPLOADED FOR NCOA ***
COPY fields record_id, first, last, address, address2, city, state, zip to ALLTRIM(lcJobDir)+"NCOA-"+alltrim(listno)+".csv" DELIMITED WITH "" with CHARACTER tab
*** GOES TO THAT DIRECTORY ***
cExport="e:\working\ncoa\incoming"
SET DEFAULT TO "&cExport"
**************PROBLEM COMMAND ******************** (had to use single quotes around command)
STRTOFILE('e:\working\ncoa\incoming\truencoa.exe "E:\working\ncoa\incoming\NCOA-"+ALLTRIM(LISTNO)+".csv" "username" "pass" " true"','e:\working\ncoa\incoming\truencoa.bat')
Can anyone help with this? probably an easy fix....
Elena