views:

6

answers:

0

Hi,

I have created a procedure in VBA 6.5 for Outlook - all new messages should be treated by this procedure but they are not.

I create rule by going to RUles and Alerts in Tools option. Then do not choose anything to treat for all incoming emails, then I click run a script -> choose the script.

This is script:

    Sub Mytest(Item As Outlook.MailItem)

strTimeStamp = Format(Item.ReceivedTime, "hh.mm AM/PM")
    'If strTimeStamp > "07.00 AM" And strTimeStamp < "12.00 PM" Then
MsgBox "OK"
Dim myDestFolder As Outlook.MAPIFolder
Dim objPersonalFolders As Outlook.MAPIFolder
objPersonalFolders = objNS.Folders("PersonalFolders").Folders("!Test").Folders("07:00 - 12:00")
Item.Move objPersonalFolder
   ' End If
End Sub

Please advise what to do :( Calling procudure worked before with msgbox "ok".. Even MSGBOX "OK" doesn't launch !