how to find outlook user settings programmatically

  • Thread starter Thread starter Shiv Kotagal
  • Start date Start date
S

Shiv Kotagal

Hi ,
I have a COM Add-In in which I am trapping the 'Reply'
and 'Reply All' events to create custom replies. My
problem is I need to insert a signature in the reply
mailitem if the user has the set it up in the tools-
options->mail format settings. How do I programmatically
find whether a user has signature settings and insert the
signature in my custom Reply Email ?

Help please, any clue on this will be greatly
appreciated !!!

Regards,
Shiv
 
The signature information is in the Windows registry, although I don't have the exact location at the tip of my fingers. One way to get the user's default signature is to create a new message. Sample code at http://www.outlookcode.com/codedetail.aspx?id=162 . Otherwise, you have to poke around for the actual signature files.
--
Sue Mosher, Outlook MVP
Outlook and Exchange solutions at http://www.slipstick.com
Author of
Microsoft Outlook Programming: Jumpstart
for Administrators, Power Users, and Developers
 
Thanks Sue, for replying so promptly. I understand your
solution of how to create the signature in a new email,
but yet I still need to find out whether or not, the user
has opted in the user settings to have a signature
automatically inserted in his new emails or reply emails.
I tried to look at the registry but couldnt find the
signature settings. Do you have any suggestions about how
to do this ?

Thanks a million,
Shiv
-----Original Message-----
The signature information is in the Windows registry,
although I don't have the exact location at the tip of my
fingers. One way to get the user's default signature is to
create a new message. Sample code at
http://www.outlookcode.com/codedetail.aspx?id=162 .
Otherwise, you have to poke around for the actual
signature files.
 
What I would do is set up a user that *does* have signatures set and look in the registry for related settings. Depending on the Outlook version, you may need to look both in Outlook and Word keys.

As a general technique, there are also registry comparison tools available that will take before and after snapshots of the registry for you to compare.
--
Sue Mosher, Outlook MVP
Outlook and Exchange solutions at http://www.slipstick.com
Author of
Microsoft Outlook Programming: Jumpstart
for Administrators, Power Users, and Developers
 
This is the location of the 2 signature settings. These keys will only exist
if a signature is selected for either of them.

HKEY_CURRENT_USER\Software\Microsoft\Office\10.0\Common\MailSettings\NewSign
ature
HKEY_CURRENT_USER\Software\Microsoft\Office\10.0\Common\MailSettings\ReplySi
gnature

The 10.0 is the location for Outlook 2002.

Does anyone know the best way to figure out what version of Outlook is
installed to know what version number to use where the 10.0 is? I found some
example code that creates a new email and gets the version number from it.
The problem is it has to save the email to get the version then deletes the
email ... each of these blank deleted email end up accumulating in the
Deleted items folder.

I would like a way outside of Outlook through VB6.0 to get the installed
version of Outlook. Is this possible?

Any help on this would be greatly appreciated.

Thanks,
Marc

---------------

What I would do is set up a user that *does* have signatures set and look in
the registry for related settings. Depending on the Outlook version, you may
need to look both in Outlook and Word keys.

As a general technique, there are also registry comparison tools available
that will take before and after snapshots of the registry for you to
compare.
--
Sue Mosher, Outlook MVP
Outlook and Exchange solutions at http://www.slipstick.com
Author of
Microsoft Outlook Programming: Jumpstart
for Administrators, Power Users, and Developers
 
I just use the Application.Version property and trap the error you get if it's Outlook 97.
--
Sue Mosher, Outlook MVP
Outlook and Exchange solutions at http://www.slipstick.com
Author of
Microsoft Outlook Programming: Jumpstart
for Administrators, Power Users, and Developers
 
Back
Top