Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Detect user cancels email send
Message
De
28/09/2011 17:07:57
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Titre:
Detect user cancels email send
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows XP SP2
Network:
Windows 2003 Server
Database:
Visual FoxPro
Divers
Thread ID:
01525141
Message ID:
01525141
Vues:
88
I'm pretty sure I've seen the solution to this on UT, but can not track it down.
When automating the sending of email via Outlook, how do I detect if the user has closed the email without sending the email?
i.e. how do I get a return value from the display() method in the following code, and what would it be in the case of the user aborting the send ?
loApplication=CREATEOBJECT("Outlook.Application")
loNameSpace=loApplication.GetNameSpace("MAPI")
loOutBox=loNameSpace.GetDefaultFolder(4)

* Create message object
THIS.oMessage=loOutBox.Items.Add
WITH THIS.oMessage
  .Body=THIS.cBodyText
  .Subject=THIS.cSubject
  IF llShowOutlook
      .display()
  ELSE
    .Send()
  ENDIF
ENDWITH
Thanks
Barry Sutton
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform