+ Reply to Thread
Results 1 to 1 of 1

Outlook / VBA Help

  1. #1
    Registered User
    Join Date
    02-15-2014
    Location
    Michigan
    MS-Off Ver
    Excel 2013
    Posts
    61

    Outlook / VBA Help

    Okay,

    I have a portion of VBA that is doing part of what I need. Let me explain my end goal first.

    We have a calendar management requirement for management to requires their calendars to be completed for the next week by EOD Thursday. I am in charge of running this and every Friday morning I open outlook, open calendar groups (closing my personal default one), update folders to ensure the calendars have all updated. I move the calendar (week view) to the next week and take a snippet of the calendar saving it in an archive. Once all compiled I send a notice out to the team to review their calendars if necessary.

    So what I have Outlook doing is opening a calendar group with the code below. What I need it to do is close the default calendar, advance to the next calendar week and "update". Since Outlook doesn't appear to support macro recording I have no idea what any of the fields are called or where to begin on this other than what I have below. Any help on the code and/or how to identify the items in outlook and calls I should be using is greatly appreciated. Once I can get Outlook to perform this I will set a bat file to open it at a set time and utilize another tool to screenshot this for me for when I'm not in the office.


    HTML Code: 
    Private Sub Application_Startup()
       
        Dim olPane As NavigationPane
        Dim olMod As CalendarModule
        Dim olGrp As NavigationGroup
        Dim olNavFld As NavigationFolder
        Dim olCalFld As Folder
        
        Set Application.ActiveExplorer.CurrentFolder = Session.GetDefaultFolder(olFolderCalendar)
        Set olCalFld = Session.GetDefaultFolder(olFolderCalendar)
        Set olPane = Application.ActiveExplorer.NavigationPane
        Set olMod = olPane.Modules.GetNavigationModule(olModuleCalendar)
        Set olGrp = olMod.NavigationGroups.Item("Shared Calendars")
       
        For I = 1 To olGrp.NavigationFolders.Count
            Set olNavFld = olGrp.NavigationFolders.Item(I)
            olNavFld.IsSelected = True
        Next
    
    End Sub
    Last edited by 6StringJazzer; 11-06-2018 at 10:16 AM. Reason: Moved from Excel Programming / VBA / Macros

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 1
    Last Post: 08-21-2018, 01:48 PM
  2. [SOLVED] VBA adding default outlook signature to an outlook html message
    By jlive24 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 07-11-2018, 11:59 AM
  3. Outlook VBA needed for Counting emails in outlook by specific date
    By Marijke in forum Outlook Formatting & Functions
    Replies: 0
    Last Post: 07-12-2017, 10:12 AM
  4. Outlook 2007, Referencing mail Item created from outlook template
    By thusidie in forum Outlook Programming / VBA / Macros
    Replies: 2
    Last Post: 07-21-2014, 04:33 PM
  5. [SOLVED] Using Exell VBA to launch Outlook Email while separating lines in the body of Outlook.
    By Tazyote in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 12-27-2013, 01:18 PM
  6. [SOLVED] VBA Macro to print to Pdf format and place as attachment in Outlook (Excel & Outlook 2007)
    By Webman1012 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-29-2013, 01:25 PM
  7. Share Task From Outlook 2010 to Outlook 2007 and Vice Versa
    By Hudas in forum Outlook Formatting & Functions
    Replies: 0
    Last Post: 10-22-2012, 03:01 PM

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1