Showing results for 
Search instead for 
Do you mean 
Reply
Solved! Go to solution

waituntil with global variables

Hi everybody,

 

how do I check in the attached situation my global variable "Umlagern_Puffer6 to -11" in my waituntil-statement?

 

The method you see in the picture is the exit method of the buffers behind the SingProc's.

 

Thanks in advance and best regards,

Henner

4 REPLIES

Re: waituntil with global variables

Here is the ScreenShot i wanted to attache. Sorry Smiley Very Happy

Solution
Solution
Accepted by topic author HennerT
‎03-10-2017 05:01 AM

Re: waituntil with global variables

[ Edited ]

Hello Henner,

Try the following code:

var VarName := str_to_obj("Umlagern_"+?.name)
waituntil VarName.value

 

str_to_obj returns the variable object. To get its value you can use its attribute 'value'.

Regards,

Ralf

Re: waituntil with global variables

Works perfectly.

 

I have tried

 

waituntil str_to_obj("Umlagern_"+?.name).value

- before but that doesn't work. Could you explane me the difference between those?

 

 

Best Regards,

Henner

Re: waituntil with global variables

waituntil needs an expression that can be 'watched'. Most of the object attributes can be watched. You can see this in the 'Show Attributes and Methods' (F8) dialog. Function calls on the other hand cannot be watched. So only a simple path is allowed.
Regards,

Ralf