Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8286133
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T11:38:15+00:00 2026-06-08T11:38:15+00:00

I have a .dotm template file on a network share. There are macros with

  • 0

I have a .dotm template file on a network share. There are macros with references to the Word, Office, and Outlook object libraries. We use two different platforms, Windows XP and Windows 7, along with Microsoft Office 2007 and Office 2010. When users open the template file the references for Word and Office adjust automatic and accordingly (that is, they’re set to Microsoft Word 12 Object Library or Microsoft Word 14 Object Library as needed), and the macros run without a problem.

Microsoft Outlook Object Library switches properly from version 12 to 14. It does not switch properly from version 14 to 12. In that case, it gives the error that the libary is not found. Is this a bug? Is there a workaround? Something I’m overlooking?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-08T11:38:16+00:00Added an answer on June 8, 2026 at 11:38 am

    ForEachLoop,

    It appears that your question has largely been answered. I will merely add a bit of information for clarity’s sake, and to provide this question with an answer. A user on the Microsoft Forums, Ossiemac, noted that LateBinding was the way to go, as has been stated by Siddarth Rout. As implied by Siddarth, that means you do not have to worry about references.

    Ossiemac provided some sample code for using the LateBinding in the sending of an email, which I have reformatted and placed here:

    Private Sub btnLateBindMethod_Click()
        ' Variables used for LateBinding
        Dim objOutlook As Object    'Outlook.Application  
        Dim objEmail As Object      'Outlook.MailItem     
        Dim objNameSpace As Object  'Outlook.NameSpace    
        Const OutLookMailItem As Long = 0    'For Late Binding
        Const OutLookFolderInbox As Long = 6 'For Late Binding
        Const OutLookFormatHTML As Long = 2  'For Late Binding
        Dim strSubject As String
        Dim strAddress As String
    
    
    On Error Resume Next
    Set objOutlook = GetObject(, "Outlook.Application")
    On Error GoTo 0     
    
        If objOutlook Is Nothing Then
            Set objOutlook = CreateObject("Outlook.Application")
            Set objNameSpace = objOutlook.GetNamespace("MAPI")
            objNameSpace.GetDefaultFolder(OutLookFolderInbox).Display
        End If
    
    Set objEmail = objOutlook.CreateItem(OutLookMailItem)
    
    strSubject = "Hello World"
    
        With objEmail
    
            '.To = strToAddress  'Commented to prevent accidental send
    
            .Subject = strSubject
    
            .BodyFormat = OutLookFormatHTML
    
            .Display
    
            'Full Name of window can change depending on Tools -> Options -> Mail Format
            'Changing this option for outgoing mail changes the window name.
            'However, AppActivate appears not to require entire name but needs up to end
            'of - Message which is included in heading following the Subject string
            'irrespective of the Mail Format option chosen.
            AppActivate (strSubject & " - Message")
    
        End With    
    End Sub
    

    Jimmy Pena has an article discussing the contrast of EarlyBinding and LateBinding –

    ~JOL

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a very simple Word sub in a dotm template: Sub YHelloThar(msg As
Background: I have an extensive set of specialized VBA macros used in Word for
I have built template-based add ins for Word and Excel version 2003 and previous.
have written this little class, which generates a UUID every time an object of
I have a macro that creates a new document based on a template stored
Have a network location that shows paths in the 8.3 short format. I need
have the following text file: <div> <asp:HyperLinkField HeaderText=Hello World of Regular Expression /> </div>
Have an app that can use tts to read text messages. It can also
Have you ever tried working with a XAML file which contains thousand tons of
Have you ever seen any of there error messages? -- SQL Server 2000 Could

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.