Troubleshooting
String concatenation working with setexpression?
Started by electrofux on .
Sign in or create an account to join the conversation.
Why is the following code not working:
On x:
decl patnum ='Pattern'+PatternNumber;
setexpression(patnum,'Direction',firstof(x));
On x:
decl patnum ='Pattern'+PatternNumber;
setexpression(patnum,'Direction',firstof(x));
What IS pattern? Is it an object? if so....
decl patnum=findobject('Pattern'+PatternNumber);
setexpression(patnum,'Direction',firstof(x));
will workGenerally speaking, and I dont know why this took me so long to understand is the difference between
a referenced object, for example Switches and the string value 'Switches'
In the manual of Lemur whenever in the reference the word "object" is used...you need a real actual reference to the object - findobject(string-name-of-object) - in our example, Switches.
Whenever the word "name" is used, then you are looking for the string ('Switches')
a referenced object, for example Switches and the string value 'Switches'
In the manual of Lemur whenever in the reference the word "object" is used...you need a real actual reference to the object - findobject(string-name-of-object) - in our example, Switches.
Whenever the word "name" is used, then you are looking for the string ('Switches')
The Object is Pattern1, Pattern2, Pattern3- all containers with variables like "Direction" in them. Thought i could directly reference them with the new feature.Softcore wrote:What IS pattern? Is it an object? if so....
will workdecl patnum=findobject('Pattern'+PatternNumber); setexpression(patnum,'Direction',firstof(x));
But findobject is cool , should work. Thx again.
Cheers
works like a charm. Thx 