We use a DOT provided workspace which uses VBA to load various Barmenu files. The Macro reads the file name and grabs the initial three characters and loads the MDF files based upon what it finds.
I would like to migrate that to named expressions with menu customizations that use a show and hide toggle based upon the named expression. This seems like a natural progression since we can import the Barmenu files using one of the Bentley utilities.
This will be my first venture into Named Expressions, so I am looking for any suggestions or caveats that may burst my bubble.
TIA.
Hi caddcop,
welcome in Named Expression adventure! ;-)
The Named Expression with the required functionality is System.String.CompareI(System.String.Substring(System.Path.GetFileName(ActiveFile.FileName),0,3),"AAA"), where "AAA" is 3 chars long tested string.
Because as you told you have just begun with the expression, here is the functionality explanation, going from inside to outside:
Attached is captured Named Expressions dialog, don't forget to check User interface keyword, so the expression will be displayed as available test in Customize dialog.
With regards,
Jan
Bentley Accredited Developer: iTwin Platform - AssociateLabyrinth Technology | dev.notes() | cad.point
Answer Verified By: caddcop