Results 1 to 5 of 5
  1. #1
    Silver Lounger
    Join Date
    Jan 2001
    Location
    Northern, California, USA
    Posts
    1,886
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Macro a Signature? (2005)

    Greetings Team,

    So, the powers that be have decided that a single signature is the way to go, for everyone. I'd like to create a macro in Outlook to automate the process of defining the standard signature, but have no idea if it's possible. The process i'd like to use is:

    1.) Locate signature files (.html, .txt, .rtf)
    2.) Copy signatures files into local users folder.
    3.) Prompt users for Name, Title, Department, Extension Number, Email Address, etc.

    Can it be done?

    Thanks!
    <IMG SRC=http://www.wopr.com/w3tuserpics/Kel_sig.gif>
    Moderator:<font color=448800> Pix Place, Internet Explorer</font color=448800>
    <small>www.kvisions.com

  2. #2
    Uranium Lounger
    Join Date
    Dec 2000
    Location
    Salt Lake City, Utah, USA
    Posts
    9,508
    Thanks
    0
    Thanked 6 Times in 6 Posts

    Re: Macro a Signature? (2005)

    Yes, but a few questions:

    Signatures should already be in a user local folder, in OS XP with either Office XP and Office 2003 environments:
    Cocuments and Settings<username>Application DataMicrosoftSignatures
    ... so why do you need to copy it? And why not go directly to step 3? (Also, they may not be consistently populated, but you may be able get Step 3 info from the Global Address List per-user Properties.)

    Is it the order and sructure of the Sig that management wants to impose?
    -John ... I float in liquid gardens
    UTC -7ąDS

  3. #3
    Silver Lounger
    Join Date
    Jan 2001
    Location
    Northern, California, USA
    Posts
    1,886
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Macro a Signature? (2005)

    The challenge I'm having is that the signature contains an image file, which also has to be migrated into the signatures folder. Additionally, the signature is structured in two columns in HTML, and has distinct looks in its rtf and txt versions.

    Also, i'm not sure what controls are used in outlook vba to define the properties of a signature. Does this help? [img]/forums/images/smilies/smile.gif[/img]

    Thanks!
    <IMG SRC=http://www.wopr.com/w3tuserpics/Kel_sig.gif>
    Moderator:<font color=448800> Pix Place, Internet Explorer</font color=448800>
    <small>www.kvisions.com

  4. #4
    Uranium Lounger
    Join Date
    Dec 2000
    Location
    Salt Lake City, Utah, USA
    Posts
    9,508
    Thanks
    0
    Thanked 6 Times in 6 Posts

    Re: Macro a Signature? (2005)

    The bad news is that Signatures are not exposed in the Outlook Object Model; you can do some simple manipulation of the files through standard VB file operations, but not directly access sigs. Coders can't even access the switches that tell Outlook to use signatures (except through SendKeys).

    With the kind of layout complexity you are proposing you would be best off using Word as your engine to obtain the user information and populate the Sigs in the Sig File, set them as read-only, and tell users they get fired if they change them. For sources of user information you could access the current user session and then resolve information from the GAL, but if the GAL isn't consistently populated, you'd be best off doing something like sending out Word template to every user containing a userform with "Fill in the blanks" for the required information, then integrating it with your three alternative structured Sigs, and writing them to the default user Sig location. (Quite a bit of work.)

    For some references to the Outlook Object Model (if only to illustrate what isn't exposed) see:
    http://www.microeye.com/resources/ObjectModel2003.htm
    http://msdn.microsoft.com/library/default...._HV01136199.asp
    -John ... I float in liquid gardens
    UTC -7ąDS

  5. #5
    Super Moderator jscher2000's Avatar
    Join Date
    Feb 2001
    Location
    Silicon Valley, USA
    Posts
    23,112
    Thanks
    5
    Thanked 93 Times in 89 Posts

    Re: Macro a Signature? (2005)

    I created an HTML Application (.hta) for our users to generate their new signatures when we changed buildings. The image was inserted as a link to a file on the company web site. Outlook users can set as a default to "include image from the internet" in an HTML message or leave it as a link. I guess with the advent of blocking images by default, including it is much safer. Anyway, HTAs have "super" privileges to write to the system so it's no problem to just copy the image to the signature folder when saving the signature.

    I can't remember where this HTA is at the moment, but if I find it, I will see whether I can pass it along. (Carefully, as HTAs are high risk and we don't want users to run them unless we wrote them!)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •