Guest User

Untitled

a guest
Mar 21st, 2018
78
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.52 KB | None | 0 0
  1. PrivateSub Application_ItemSend(ByVal Item AsObject, Cancel AsBoolean)
  2.  
  3. OnErrorResumeNext
  4. ' use lower case for the address
  5. ' LCase converts all addresses in the To field to lower case
  6. If StrComp((Item.SenderEmailAddress),"bad.email@gmail.com")Then
  7. ExitSub
  8. EndIf
  9.  
  10. Prompt$="You sending this from "& Item.SenderEmailAddress &". Are you sure you want to send it?"
  11. If MsgBox(Prompt$, vbYesNo + vbQuestion + vbMsgBoxSetForeground,"Check Address")= vbNo Then
  12. Cancel =True
  13. EndIf
  14.  
  15. EndSub
Add Comment
Please, Sign In to add comment