General

General

How can I use an external text file in ICEM script?

    • FAQFAQ
      Participant

      In the replay file use the following lines set inputfile [open “input.txt”] set lineNumber 0 gets $inputfile comp1 gets $inputfile comp2 close $inputfile ic_mess “comp1: $comp1 n” red ic_mess “comp2: $comp2 n” red These will open the file input.txt, read the two first lines and place the value in the variables of comp1 and comp2, respectively. To refer to the variables in the script use: $comp1 and $comp2. The latter two lines will print the value in the message window. The lines in input.txt should be: 30 15