Hi,

Why a string variable loses it's value during a long test?
I would like to save information into a file and for that I have to create a file and then save the data into the file. I save the data at the end of the test and in the INITRUN I create the file. I save the destination of the file into a string variable:
Code
string LogDestination = strf("Log\\%s_%s.txt", LogDate, Asset);

Zorro creates the file in the Log folder as supposed then run the test. At the end of the test I would like to save the data but I get error (ab.22). I figured it out that the LogDestination doesn't hold the string, it is overwritten during the test. I created one string variable and allocated memory to it where I save the data during the test. And somehow the LogDestination is overwritten by that data.
Should I allocate memory for LogDestination variable to keep it's value? Is this a normal behaviour?
I read that character array should solve this kind of problem. I have more string variables and I don't want to end up with incorrect data in my log file.