Aqui está um script semelhante que pode ajudar.
Meu caso de uso é um pouco diferente: seleciono manualmente itens em uma visualização personalizada e, em seguida, o roteiro em um botão da barra de ferramentas. (Eu acho que as conversas não são devidamente controladas, e às vezes uma conversa diverge em projetos diferentes.)
Option Explicit
Option Base 0
Public Sub MoveToFirstFolder()
Dim oNamespace As Outlook.NameSpace, oSelection As Outlook.Selection
Dim oFolder As Outlook.MAPIFolder
Dim oItem As Object, i As Integer
Set oNamespace = Application.GetNamespace("MAPI")
Set oSelection = oNamespace.Application.ActiveExplorer.Selection
If oSelection.Count < 2 Then Exit Sub
Set oFolder = getFirstNonDefaultFolder(oSelection)
If oFolder Is Nothing Then Exit Sub
' move items
For i = 1 To oSelection.Count
Set oItem = oSelection.Item(i)
If Not oItem.Parent = oFolder Then
oSelection.Item(i).Move oFolder
End If
Next i
End Sub
Private Function getFirstNonDefaultFolder(oSelection As Outlook.Selection) As Outlook.Folder
Dim oItem As Object
Dim oFolder As Outlook.Folder
Dim i As Integer
' get folder
For i = 1 To oSelection.Count
Set oFolder = oSelection.Item(i).Parent
Debug.Print ">" & oFolder.FullFolderPath
If Not isDefaultFolder(oFolder) Then
Set getFirstNonDefaultFolder = oFolder
Exit Function
End If
Next i
End Function
Private Function isDefaultFolder(oFolder As Outlook.Folder) As Boolean
Dim oNamespace As Outlook.NameSpace
Dim defaultFolders, fldrNum
isDefaultFolder = False
defaultFolders = Array( _
olFolderInbox, olFolderSentMail, _
olFolderDrafts, _
olFolderDeletedItems, olFolderJunk, _
olFolderOutbox, _
olFolderCalendar, _
olFolderContacts, olFolderSuggestedContacts, _
olFolderNotes, _
olFolderTasks, olFolderToDo, _
olFolderJournal, _
olFolderConflicts, olFolderLocalFailures, olFolderServerFailures, olFolderSyncIssues, _
olFolderManagedEmail, olPublicFoldersAllPublicFolders _
)
Set oNamespace = Application.GetNamespace("MAPI")
On Error Resume Next ' Non-existant DefaultFolders cause errors
For Each fldrNum In defaultFolders
If oFolder = oNamespace.GetDefaultFolder(fldrNum) Then
If Err.Number Then
Err.Clear
Else
isDefaultFolder = True
Exit Function
End If
End If
Next fldrNum
End Function