+ Reply to Thread
Results 1 to 2 of 2

Thread: all folders needs to be saved in hard except Drafts and Sent Items

  1. #1
    Registered User
    Join Date
    03-21-2009
    Location
    Bangalore
    MS-Off Ver
    Excel 2003
    Posts
    57

    all folders needs to be saved in hard except Drafts and Sent Items

    Hi All,

    I want to copy all the folders from outlook to hard disk except Drafts and Sent Items. The following code is copying all the folders. Please kindly tell me the way how can we avoid Drafts and Sent Items folders.

    Sub GetFolder(Folders As Collection, EntryID As Collection, StoreID As Collection, Fld As MAPIFolder)
         
        Dim SubFolder       As MAPIFolder
         
         
        Folders.Add Fld.FolderPath
        EntryID.Add Fld.EntryID
        StoreID.Add Fld.StoreID
        For Each SubFolder In Fld.Folders
          ' If Fld.Folders = "Sent items" Or "Drafts" Then
          ' Resume Next
            GetFolder Folders, EntryID, StoreID, SubFolder
           'End If
        Next SubFolder
         
    ExitSub:
         
        Set SubFolder = Nothing
         
    End Sub
    Thanks & Regards
    Ramesh

  2. #2
    Registered User
    Join Date
    11-09-2008
    Location
    germany
    Posts
    74

    Re: all folders needs to be saved in hard except Drafts and Sent Items

    What happens which you check the NAME property of the folder eg

    IF NOT Fld.Name = "Drafts" then
    "do your magic"
    end if

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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.2.0