Checking if an optional panel is open

The View > Optional Panels menu lists the optional panels of the current layout. In the default layout, this includes the main command panel (MCP), the timeline, time range slider, and the Main Shelf.

To check if a panel is open, get the panel from the ActiveLayout.Views collection and check whether it’s visible:

LogMessage( Application.Desktop.ActiveLayout.Views("main_shelf").Visible );

2 thoughts on “Checking if an optional panel is open

    • Someone on xsibase asked this, but they didn’t say what they were doing. Maybe they want to hide the optional panel if it is visible, or update it somehow if it is visible.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s