I don't know why, but the parameter AC_StoryNumber is a TEXT type, even though the story number will always be an integer. This makes it unreliable to test in GDL whether the current story falls inside / outside a selected range, particularly when testing for negative stories (e.g. IF AC_StoryNumber >= -2 AND AC_StoryNumber <= 6 THEN).
Is there any way to query the current story (in a Story Marker, in this instance) to return an integer?
Thanks for this - unfortunately it doesn't solve the fundamental problem of Archicad returning a text parameter for the current story in the Story Marker.
The way I solved it was to create a separate array filled with the story numbers as integers, then run a loop to match the current story (it will find an equal to with a string, but not a less-than / greater-than) with the array value. Then I declare a variable with that integer.