Check BOM browser is opened

Check BOM browser is opened

dibujocad
Enthusiast Enthusiast
588 Views
4 Replies
Message 1 of 5

Check BOM browser is opened

dibujocad
Enthusiast
Enthusiast

Hi, I need to check if BOM browser is opened in the active assembly.

I found this code to execute it, but I cannot find anything related to check if it's opened.

Any suggestion?

 

ThisApplication.CommandManager.ControlDefinitions.item("AssemblyBillOfMaterialsCmd").execute

0 Likes
Accepted solutions (1)
589 Views
4 Replies
Replies (4)
Message 2 of 5

matt_jlt
Collaborator
Collaborator

only thing i can think of is using the windows / win32 API which is not really a simple implementation

look at this post from a while ago for a starting point.

https://forums.autodesk.com/t5/inventor-ilogic-api-vba-forum/get-vault-check-in-window/m-p/10629398/...

 

Essentially you would have to call a command that gets the active windows and looks for one that has either a complete or partial name match to the one you want.

0 Likes
Message 3 of 5

Ralf_Krieg
Advisor
Advisor
Accepted solution

Hello

 

AFAIK as long as the BOM window is open, ThisApplication.CommandManager.ActiveCommand="AssemblyBillOfMaterialsCmd".


R. Krieg
RKW Solutions
www.rkw-solutions.com
Message 4 of 5

matt_jlt
Collaborator
Collaborator

I didn't even think of doing that, genius. Thanks for the tip.

0 Likes
Message 5 of 5

dibujocad
Enthusiast
Enthusiast
Thanks!! It's exactly what I was looking for
0 Likes