I just started a new job and have been thrust into writing something in TCL which I've never done before. Here's the gist of what I'm trying to do.
From the main TCL page they have created a list as follows:
SSelect bla bla bla
SL BR1
They basically did a select and then saved the list under the name BR1.
Now they want me to make a program that uses a loop to access that list, saves it under incremental names, edits the new lists, and saves them.
The new program is created by:
ED CBP MYPROGRAMNAME.MC
I'm using the following commands to retrieve list BR1 and save it according to the variable COUNTER which manages the loop.
EXECUTE-CMD = "GET-LIST BR1"
EXECUTE-CMD = "SAVE-LIST BR" : COUNTER
EXECUTE-CMD = "EDIT-LIST BR" : COUNTER
EXECUTE-CMD = "C/TEXTTOCHANGE/CHANGETO" : COUNTER : "/G9999"
EXECUTE-CMD = "FI"
*THEN I OPEN IT SORT IT AND SAVE IT AGAIN
EXECUTE-CMD = "GET-LIST BR" : COUNTER
EXECUTE "SSELECT BLA BLA BLA"
EXECUTE-CMD = "SAVE-LIST BR" : COUNTER
*THEN I INCREMENT COUNTER AND DO THE LOOP
IT SEEMS TO BE WORKING CORRECTLY, BUT IT DOESN'T SEEM TO BE USING BR1 THAT WE SAVED FROM THE MAIN TCL SCREEN, OR SAVING IN THE SAME LOCATION THAT WE SAVED THE ORIGINAL BR1 LIST.
Does TCL use a directory structure where the lists from the main screen aren't accessible from within my little program and vice versa? If so, how can I word the commands within my little program to utilize and save to that same directory???
I know it's probably a stupid question, and my programming skills are laughable, but I hope someone can help.
-mike
From the main TCL page they have created a list as follows:
SSelect bla bla bla
SL BR1
They basically did a select and then saved the list under the name BR1.
Now they want me to make a program that uses a loop to access that list, saves it under incremental names, edits the new lists, and saves them.
The new program is created by:
ED CBP MYPROGRAMNAME.MC
I'm using the following commands to retrieve list BR1 and save it according to the variable COUNTER which manages the loop.
EXECUTE-CMD = "GET-LIST BR1"
EXECUTE-CMD = "SAVE-LIST BR" : COUNTER
EXECUTE-CMD = "EDIT-LIST BR" : COUNTER
EXECUTE-CMD = "C/TEXTTOCHANGE/CHANGETO" : COUNTER : "/G9999"
EXECUTE-CMD = "FI"
*THEN I OPEN IT SORT IT AND SAVE IT AGAIN
EXECUTE-CMD = "GET-LIST BR" : COUNTER
EXECUTE "SSELECT BLA BLA BLA"
EXECUTE-CMD = "SAVE-LIST BR" : COUNTER
*THEN I INCREMENT COUNTER AND DO THE LOOP
IT SEEMS TO BE WORKING CORRECTLY, BUT IT DOESN'T SEEM TO BE USING BR1 THAT WE SAVED FROM THE MAIN TCL SCREEN, OR SAVING IN THE SAME LOCATION THAT WE SAVED THE ORIGINAL BR1 LIST.
Does TCL use a directory structure where the lists from the main screen aren't accessible from within my little program and vice versa? If so, how can I word the commands within my little program to utilize and save to that same directory???
I know it's probably a stupid question, and my programming skills are laughable, but I hope someone can help.
-mike