THE BOTTOM LINEI need a Named Expression that will test whether Reference Slot Number "x" is occupied with an attachment in the active model, and if so, is it currently being displayed. If there is an attachment and it is displayed, it needs to evaluate as True by the named expression.
Alternatively, just see if Slot "x" has an attachment, whether displayed or not.
MORE INFORMATIONI have a custom toolbar that functions a little like the View Groups toolbar where the eight numbers toggle on and off views 1-8. But my toolbar displays not 1-8, but 0-20, and clicking a number (tool) would display only that ref file attachment. That is, say when I click "4", the tool would execute a command string "update file 4;selview 1" to temporarily display only reference attachment number 4 in View 1, if it exists. Just move or pan or zoom, and you are back to viewing normally.
In the interest of screen space, what I would like to do is limit the display of numbers on the custom toolbar to only the ref attach slots that really contain an attached file AND have their display turned on.
I think the technique is to add a Show/Hide test on the tool definition. I think the test will also require some Named Expression to be defined as well. I haven't figured how to write the Named Expression it will require. I think this is simple, but I don't have the skills to do it myself.
Where are some resources that can show me how to learn to make Named Expressions?
CONSIDERATIONSAssumptions - these events would/may trigger an immediate change in the toolbar:1. Moving from one model to another.2. Adding or deleting ref attachments.3. Toggling a ref Display On/Off.
Are these assumptions erroneous or good? I really don't want the toolbar expanding and contracting in size to mess up my docked arrangements.
Answer Verified By: Patrick Coyne