Set Signature Setting using VBA

S

stijnsanders

I'm looking for how to change the Signature setting in Outlook using
VBA

In VBA for Word, there's a nice EmailOptions object with everything I
need,
but I would like to create a script that sets Outlook to:
- use HTML for e-mails
- not use Word for e-mails
- use a certain generated HTML as signature
- not use the signature again when replying

I found out they're supposed to be under %USERPROFILE%\Application
Data\Microsoft\Signatures,
but then... A number of these options are in the registry, but not the
selected signature name,
but changing the registry would require outlook to restart, I guess. So
I would prefer to use VBA to change this setting from an install
script.

Anybody got any idea how?

(Have I searched the net already? Yes I have, and only found
semi-solutions that involve setting HTMLBody to the content of a
signature when composing new e-mails)
 
S

Sue Mosher [MVP-Outlook]

- use HTML for e-mails
- not use Word for e-mails

These are in the registry (you can use the Outlk##.adm file for your version to find the locations -- replace Software\Policies\Microsoft with Software\Microsoft). Setting them while Outlook is running will not affect the current session, only subsequent sessions.
- use a certain generated HTML as signature
- not use the signature again when replying

These can be set with the EmailOptions object in Word.
I would prefer to use VBA to change this setting from an install
script.

Why involve VBA? Why not just an install script?
--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003

and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
 
S

StijnSanders

I've checked the EmailOptions object in Word, and they clearly access
different settings than those shown in the Outlook mail settings
dialog. There the signature settings even gets greyed out when you
select Word as your mail editor, to have you revert to the mail
settings in Word to choose your signature.

To be clear: I don't want Word as my mail editor...

I'll look into this adm file and try to hack that one then...

Sue Mosher [MVP-Outlook] schreef:
 
S

Sue Mosher [MVP-Outlook]

If you're using Outlook 2002 or 2003, the signatures are the same regardless of which editor you're using.

--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003

and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers


StijnSanders said:
I've checked the EmailOptions object in Word, and they clearly access
different settings than those shown in the Outlook mail settings
dialog. There the signature settings even gets greyed out when you
select Word as your mail editor, to have you revert to the mail
settings in Word to choose your signature.

To be clear: I don't want Word as my mail editor...

I'll look into this adm file and try to hack that one then...

Sue Mosher [MVP-Outlook] schreef:
These are in the registry (you can use the Outlk##.adm file for your version to find the locations -- replace Software\Policies\Microsoft with Software\Microsoft). Setting them while Outlook is running will not affect the current session, only subsequent sessions.


These can be set with the EmailOptions object in Word.


Why involve VBA? Why not just an install script?
 

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