mCurPath = SYS(5) + SYS(2003) oleMAPISession = createobject( "MSMAPI.MAPISession.1" ) * Signon to mail with oleMAPISession .UserName = "" .Password = "" .DownloadMail = .f. .Signon() * Check the SignOn status if ( .SessionID > 0 ) oleMAPIMessages = createobject( "MSMAPI.MAPIMessages.1" ) * tell the message the SessionID oleMAPIMessages.SessionID = .SessionID else SET DEFAULT TO &mCurPath return endif endwith * Send an email with oleMAPIMessages .Compose() * Set the Recipient name and resolve .RecipDisplayName = "paul@businessoftware.com" .RecipType = 1 * .ResolveName() .MsgSubject = "testing" .MsgNoteText = "testing" .Send( .f. ) endwith oleMAPISession.Signoff() RELEASE oleMAPISession RELEASE oleMAPIMessage SET DEFAULT TO &mCurPath