Origin Ver. and Service Release (Select Help-->About Origin): 2018b
Operating System: Windows 10
Hello,
I am trying to define a series of strings extracted from graph names, in order to move those graphs to their corresponding folders.
An example of a graph name is: gdH1p5z650C
I want to check for the left and right parts of the name; one will define the parent folder, and the other will define the child folder to move to.
string gName$ = page.name$;
string FvarDSC$="ZnO-Temp-Var DSC";
string gFol1$;
string gFol2$;
string gFol$="/%(gFol1$)/%(gFol2$)"; //Parent/child folder path
if (Left(gname$,3)$ == "gdH") gFol1$ = "DSC";
if (Right(gName$,1)$ == "C") gFol2$=%(FvarDSC$);
I tried to use pe_move command, but an error popped up stating that the graph couldn't be moved to "//". Apparently, it is not reading the strings correctly for gFol$.
The results I obtained in my test is:
gFol1$=;
gFol2$=;
gFol$=;
DSC
ZnO-Temp-Var DSC
//
However, this changes the active folder correctly:
//From any folder
pe_cd path:=gFol$;
I have used pe_move path="/%(string$)"
successfully in previous ocassions.
What am I doing wrong? Thank you.