Outlook 2007 signature with VBA

G

Guest

Hi,
I have VBA script to create signatures in outlook 2003 to all user accounts
using AD. This worked fine until we had and XP machine with office 2007. The
script still creates the signature files but when the user creates new emails
the signature is using double spacing.

I opened the word file that was created by the script, with word 2007 and I
noticed that it is using 1.15 line spacing and the normal style. It seems
that when i change to the No Spacing style then it is fine.

My question is why the formatting has changed when outlook 2007 is used?

Many thanks
 
G

Guest

Nile,

If you are using Word to create the signature, try adding:
ParagraphFormat.SpaceAfter=0

I think this worked for OL2007, if not, then instead of using
TypeParagraph() for new lines which I believe is interpreted as a Carriage
Return and Line Feed in Outlook 2007, use Chr(11) which is just a CR.

eg. Selection.TypeText text:=Chr(11).

Hope this helps

Chris.
 

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