vbaoutlookoutlook-2010

reply with template in outlook 2010


As a continuous process to improve our customer service at our helpdesk I'm looking to integrate a functionality in our outlook so that we can reply to existing e-mails using outlook template's (.oft).

My search online mostly gave me results for auto-reply'ing. However this is not what I (we) need.

We are in need for a tool that enables us to select from a list of standard templates (with subject oriented reply's). http://replywith.4team.biz/ Gives a solution in the right direction, however, as with any company, we would like a free tool.

Is this programmable in VBA? And if so, how?


Solution

  • VBA sample based on http://msdn.microsoft.com/en-us/library/office/ff865637.aspx

    Sub CreateReplyFromTemplate() 
     
        dim currItem  As Outlook.MailItem 
        dim currItemReply  As Outlook.MailItem 
        Dim MyItem As Outlook.MailItem 
     
        set currItem = activeinspector.currentitem
        Set curritemReply = currItem.Reply
        Set MyItem = Application.CreateItemFromTemplate("C:\HelpTopic1.oft") 
    
        MyItem.To = currItemReply.To
        MyItem.htmlbody = MyItem.htmlbody  & currItemReply.htmlbody
    
        currItemReply.close oldiscard
        currItem.close  oldiscard
    
        MyItem.Display 
    
        set curritemReply = nothing
        set MyItem = nothing
        set currItem = nothing
    End Sub
    

    Deploying the VbaProject.OTM file VbaProject.OTM deployment

    Reply with a message template via Quick Steps - http://www.msoutlook.info/question/665

    Working with message templates - http://www.howto-outlook.com/howto/messagetemplates.htm