Display Outlook Options

G

Guest

Hi

Does anyone have a code snippet i can use to programmatically open the
tools->options dialog and if really good select a specific tab.
I have coded my solution with VSTO C#, but any code will be fine.

I hope somebody has done this before, or just know their way around in
Outlooks Objectmodel.

Best regards
/Anders
 
K

Ken Slovak - [MVP - Outlook]

You can't do that. You could get the ID of the command bar control object
that represents Tools, Options and call its Execute method to open the
dialog but from there you couldn't control the tabs or which one has focus.
 
G

Guest

Ok.

So if I need the user to set some "initial" parameters when the addin is
installed, and run the first time - what would be best practice there?

The only (reasonable) options i can figure out is these two:
1. A "wizard" that lets you set these settings.
2. A messagebox telling the user to open tools->options and set the missing
parameters.

The parameters can't be given a default value that make sense, since the
addin needs some filepaths to store information - and this path will be
different for most users.

Best regards
/Anders
 
K

Ken Slovak - [MVP - Outlook]

In cases like that I usually check for a first run state (maybe blank values
in the registry or an INI file) and display a configuration dialog form. I
leave access to the Tools, Options tab for the user. A wizard is an
alternative.
 
G

Guest

Yes, the same form can almost be reused in an initial configuration window as
the one in tools, options.

I'll take a look at it. Thanks for the response, it's always nice to know
when something you're trying to do can't be done - and you can stop looking
for a solution.

/Anders
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top