Results 1 to 9 of 9

Thread: How do I deploy an Outlook macro - no exchange server

  1. #1

    Thread Starter
    New Member
    Join Date
    May 2006
    Posts
    3

    How do I deploy an Outlook macro - no exchange server

    Hi,

    The group I work for uses MS Outlook, however there's no Exchange server. Users have POP accounts and use the calendar locally.

    I have a macro I wish to distribute to that user base, but unlike VB itself there doesn't sem to be a way to "make" anything out of the macro that I could distribute.

    This macro has a few custom forms, modules, and a class and it all WORKS fine, I just don't see a way to hand it off to another user and say "Here, load this up and have at it." etc.

    One other thing - while the macro "runs" ok, even when I have the VBE closed, after it gets done running it opens up the VBE and just sits there - is there anyway to make THAT stop?

  2. #2
    Ex-Super Mod RobDog888's Avatar
    Join Date
    Apr 2001
    Location
    LA, Calif. Raiders #1 AKA:Gangsta Yoda™
    Posts
    60,709

    Re: How do I deploy an Outlook macro - no exchange server

    Welcome to the forums.

    Sounds like your macro code has a possible error?
    VB/Office Guru™ (AKA: Gangsta Yoda®)
    I dont answer coding questions via PM. Please post a thread in the appropriate forum.

    Microsoft MVP 2006-2011
    Office Development FAQ (C#, VB.NET, VB 6, VBA)
    Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
    If a post has helped you then Please Rate it!
    Reps & Rating PostsVS.NET on Vista Multiple .NET Framework Versions Office Primary Interop AssembliesVB/Office Guru™ Word SpellChecker™.NETVB/Office Guru™ Word SpellChecker™ VB6VB.NET Attributes Ex.Outlook Global Address ListAPI Viewer utility.NET API Viewer Utility
    System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6

  3. #3

    Thread Starter
    New Member
    Join Date
    May 2006
    Posts
    3

    Re: How do I deploy an Outlook macro - no exchange server

    If there is an error it's not saying anything about it and all things it was supposed get done do in fact get done. When the VBE comes up it's not in pause mode or in need of hitting the "stop" button. I'm using the "End" keyword - is that a no-no in VBA?

  4. #4
    Ex-Super Mod RobDog888's Avatar
    Join Date
    Apr 2001
    Location
    LA, Calif. Raiders #1 AKA:Gangsta Yoda™
    Posts
    60,709

    Re: How do I deploy an Outlook macro - no exchange server

    Then "End" keyword is whats making it open the IDE. Its a big no-no in both VBA and VB 6. There should be no reason to use End in VBA.
    VB/Office Guru™ (AKA: Gangsta Yoda®)
    I dont answer coding questions via PM. Please post a thread in the appropriate forum.

    Microsoft MVP 2006-2011
    Office Development FAQ (C#, VB.NET, VB 6, VBA)
    Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
    If a post has helped you then Please Rate it!
    Reps & Rating PostsVS.NET on Vista Multiple .NET Framework Versions Office Primary Interop AssembliesVB/Office Guru™ Word SpellChecker™.NETVB/Office Guru™ Word SpellChecker™ VB6VB.NET Attributes Ex.Outlook Global Address ListAPI Viewer utility.NET API Viewer Utility
    System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6

  5. #5
    Frenzied Member David.Poundall's Avatar
    Join Date
    Sep 2002
    Location
    Robin Hood Land
    Posts
    1,457

    Re: How do I deploy an Outlook macro - no exchange server

    Sorry all, but to BUMP the original question, how do you go about distributing a macro to a stand alone outlook installation then ?
    David

    Learn the Rules so that you know how to break them properly.

    Printing dll dBTools MZTools Winsock API WinsockVB More Winsock SGrid2 MSChart Mail2Web

    If you have found this thread useful then read this

  6. #6
    Ex-Super Mod RobDog888's Avatar
    Join Date
    Apr 2001
    Location
    LA, Calif. Raiders #1 AKA:Gangsta Yoda™
    Posts
    60,709

    Re: How do I deploy an Outlook macro - no exchange server

    One way is to copy the VbaProject.OTM file from one system to another. The VbaProject.OTM contains all the VBA code. This will work for 2003 but for 2000 and 2002 you need to open the VBA editor in order to link the Application_ events to fire.

    The location of the VbaProject.OTM file is:
    Userprofile\Application Data\Microsoft\Outlook\VBAProject.OTM


    Another would be to use manually export each .cls, frm, .bas file and copy them over and do a Import for each one, but its allot of work if you have allot to do.

    Finally, there is the Office Profile Wizard.

    Sorry for missing the second part of the initial post.
    VB/Office Guru™ (AKA: Gangsta Yoda®)
    I dont answer coding questions via PM. Please post a thread in the appropriate forum.

    Microsoft MVP 2006-2011
    Office Development FAQ (C#, VB.NET, VB 6, VBA)
    Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
    If a post has helped you then Please Rate it!
    Reps & Rating PostsVS.NET on Vista Multiple .NET Framework Versions Office Primary Interop AssembliesVB/Office Guru™ Word SpellChecker™.NETVB/Office Guru™ Word SpellChecker™ VB6VB.NET Attributes Ex.Outlook Global Address ListAPI Viewer utility.NET API Viewer Utility
    System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6

  7. #7
    Frenzied Member David.Poundall's Avatar
    Join Date
    Sep 2002
    Location
    Robin Hood Land
    Posts
    1,457

    Re: How do I deploy an Outlook macro - no exchange server

    So if I were to do an executable that were to merely copy the OTM file to the right place on a users PC, and if they had macro's enabled, all would be well (assuming 2003 and above)?
    David

    Learn the Rules so that you know how to break them properly.

    Printing dll dBTools MZTools Winsock API WinsockVB More Winsock SGrid2 MSChart Mail2Web

    If you have found this thread useful then read this

  8. #8
    Ex-Super Mod RobDog888's Avatar
    Join Date
    Apr 2001
    Location
    LA, Calif. Raiders #1 AKA:Gangsta Yoda™
    Posts
    60,709

    Re: How do I deploy an Outlook macro - no exchange server

    Yes and no. If they dont have any Macro code then its all good. But if they have their own or previously written macro code then when you copy over the VBAProject.OTM file it will wipe out whatever they had before. What you could do is check if the file exists and if it dont then do the file copy. If it does exist then open the Outlook VBA IDE and msgbox to the user that it needs to be manually copied into the VBA IDE class by class, module by module, and form by form.
    VB/Office Guru™ (AKA: Gangsta Yoda®)
    I dont answer coding questions via PM. Please post a thread in the appropriate forum.

    Microsoft MVP 2006-2011
    Office Development FAQ (C#, VB.NET, VB 6, VBA)
    Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
    If a post has helped you then Please Rate it!
    Reps & Rating PostsVS.NET on Vista Multiple .NET Framework Versions Office Primary Interop AssembliesVB/Office Guru™ Word SpellChecker™.NETVB/Office Guru™ Word SpellChecker™ VB6VB.NET Attributes Ex.Outlook Global Address ListAPI Viewer utility.NET API Viewer Utility
    System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6

  9. #9

    Thread Starter
    New Member
    Join Date
    May 2006
    Posts
    3

    Re: How do I deploy an Outlook macro - no exchange server

    Thanks you guys - my research led me to similar conclusions on the distribution. I was hoping one of the guru's might've had a trick but even so it's good to have the confirmation. Thx again!

Posting Permissions

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



Click Here to Expand Forum to Full Width