2022-01-11 11:04 PM
How do I get the layout name? I can't find a request command, or a global variable, or an AC_ variable.
I know how to do a TEXT2 0, 0, "<LAYOUTNAME>", but I can't extract this to run a STRSTR command.
_layoutName = "<LAYOUTNAME>" doesn't work.
2022-01-11 11:24 PM
hmmm... saving autotext using <LAYOUTNAME> results in a 2d script using "<LAYOUTNAME>"; and the resulting object definitely pulls the layout name from the layout that object is placed on...
screen shot of script and placed object attached...
what are you saving the script as? haven't tried drawing title and/or label, but it seems to work on my end.
2022-01-11 11:25 PM
also, are you placing the scripted elmeent on a layout or in a view? because you aren't going to be able to reference a layout from a view AFAIK
2022-01-11 11:51 PM - edited 2022-01-11 11:56 PM
AC_drawingname
Edit, my bad, just missed the ac_ part at the end.
2022-01-11 11:52 PM - edited 2022-01-11 11:54 PM
Sorry that's the drawing view,
Try AC_layoutname
NVM that doesn't work, maybe drawing name is what you want, but doubtful
2022-01-12 04:37 AM
"<LAYOUTNAME>" actually works; I think it may just be a misunderstanding of globals and where they can pull from... or over complicating; not sure what the end goal is for parameter = <GLOBAL>
2022-01-12 09:53 AM
"<LAYOUTNAME>" will work if used directly in a TEXT2 (or PARAGRAPH etc) command.
I want to take the the layout name, split it at a user-defined delimiter in order to force a carriage return and allow for separate font settings. This would be placed in the master's title block.
E.g. The layout name "CONCRETE PROFILE PLANS - GROUND FLOOR" would become:
CONCRETE PROFILE PLANS
GROUND FLOOR
In order to do this, I need to run a STRSTR command on the layout name.
2022-01-12 03:37 PM
The magic words are "HomeDB_info".
Request that 😉
2022-01-12 10:56 PM
Thanks runxel - that's what I was (mostly) looking for!
This will indeed return the layout name, and will allow me to do my STRSTR splitting. Unfortunately, it has to be placed on every layout - it won't work if placed in the master (it will always return the master layout's name).
2022-01-14 07:19 AM
GS people: any idea?