Consulting

Results 1 to 7 of 7

Thread: Mailitem from template ??

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    VBAX Regular
    Joined
    Jan 2018
    Posts
    52
    Location

    Mailitem from template ??

    I have this code to generate a mailitem BUT ... see this thread:

    http://www.vbaexpress.com/forum/show...-attach-a-file

    Unfortunately it does NOT use the same template as if I myself create a new mailitem in Outlook.

    I've tried different templates Normal.dotm, NormalEmail.dotm, MAIL.oft - I'm NOT allowed to use these files in VBA.

    Here are the code I changed:

    FROM this: Set MailOutLook = appOutLook.CreateItem(olMailItem)

    TO this: Set MailOutLook = appOutLook.CreateItemFromTemplate("C:\Users\ksor\AppData\Roaming\Microsoft\ Templates\Normal.dotm", OutLook.olMailItem)


    What do I do wrong ?
    Last edited by ksor; 03-02-2018 at 06:19 AM.

Posting Permissions

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