Hi Guys, is there a method of having a button to scroll the the next email (received after the current one) via a cmd Button ?
This is a loose attempt but my lack of understanding won't make it work at all, thank you
Code:
Dim oItem As MailItemDim outApp As Outlook.Application
Dim objItem As Object
Dim olExplorer As Outlook.Explorer
Dim sText As String, vText As Variant, i As Integer
Set oExplorer = outApp.ActiveExplorer
Set oItem = objItem
If oExplorer Is Nothing Then
MsgBox "No Outlook explorer open!", vbCritical, "No Outlook Explorer"
End If
If oExplorer <> 0 Then
For Each objItem In ActiveExplorer.Selection
With oItem
sText = oItem.Body
vText = Split(sText, Chr(13))
For i = UBound(vText) To 0 Step -1
vItem = Split(vText(i), Chr(9))
Me.txtMailMessage = vText
End With
End If
Next i
Set outApp = Nothing
Set objItem = Nothing
Set oExplorer = Nothing