We value your input!
Please participate in Archicad 28 Home Screen and Tooltips/Quick Tutorials survey

Libraries & objects
About Archicad and BIMcloud libraries, their management and migration, objects and other library parts, etc.

Dynamic variables

Anonymous
Not applicable
i am trying to make hotspots that are editable, and use a unique ID tag. i am wanting this tag to be dynamic so the unique ID is HOTSPOT<int i>

for example:

WHILE i<10 DO
Text2 0,i <prints `HOTSPOT`i>
i=i+1
endwhile

which would produce the following text:

HOTSPOT10
HOTSPOT9
...
HOTSPOT2
HOTSPOT1

i was thinking i could join the string "HOTSPOT" with INT i. i have done something like this in other languages however am not sure if it can be done with GDL. I used a TEXT2 example. however i am looking for a way to take the string that TEXT2 would have displayed and use it an the unique ID for a hotspot.

thank you.
2 REPLIES 2
Anonymous
Not applicable
I think all you need is a counter of sorts in your loop. It's discussed here.
Anonymous
Not applicable
Thank you very much! that helps alot.