TheSwamp

Code Red => .NET => Topic started by: Keith Brown on July 19, 2014, 09:18:45 AM

Title: Open Options Dialog to specific tab
Post by: Keith Brown on July 19, 2014, 09:18:45 AM
Does anyone know if it is possible using the .net api to open up the options dialog to a specific tab?  I have created a program that inserts a tab into this dialog and it would be nice to be able to create a program specific settings command that opens up this dialog to the specified tab.
Title: Re: Open Options Dialog to specific tab
Post by: Andrey Bushman on July 19, 2014, 01:57:05 PM
This question is interesting for me too, but I have not found solution in past.
Title: Re: Open Options Dialog to specific tab
Post by: Jeff_M on July 19, 2014, 02:45:08 PM
Code - C#: [Select]
  1.             Autodesk.AutoCAD.Internal.Utils.InvokeOptionsDialog("System", false, 0, false);
Replace "System" with your tab name.
Title: Re: Open Options Dialog to specific tab
Post by: LE3 on July 19, 2014, 02:47:43 PM
how about using acedCmd pinvoke or any newer approach than this now avail and +OPTIONS and then just pass the desired tab index.

Quote
Command: +OPTIONS
Tab index <0>: 3

See if works for you.


Oh... I see Jeff posted some method for this, cool.
Title: Re: Open Options Dialog to specific tab
Post by: Keith Brown on July 19, 2014, 02:50:13 PM
Thanks Jeff,  works great.


Le, that only works if you know the tab index.  For custom tabs it will be impossible to know the index.  How do you know how many custom tabs the user has?