I am trying to open a workspace from an AddOn with C#.
The basic idea is: The user picks a workspace from a list, clicks a button, the workspace opens, we wait till it is fully loaded, run some automated tests with the workspaces and close the workspace again.
I am currently struggling with the opening part. I could not find a method in the documentation which would allow me to open a workspace from an AddOn.
As a workaround I tried to get the correct MenuItem and trigger its OnClick() method. I am able to fetch the MenuItem. According to Microsoft doc MenuItems should have a PerformClick() method to simulate a user click, but it cannot be found in Visual Studio.
Does anyone has a suggestion on how to open a workspace programmatically?
Thank you all in advance.
Comment