PROCEDURE Error LPARAMETERS tnError, tcMethod, tnLine LOCAL laError[1] IF tnError = 1429 AERROR(laError) This.AddError("VFP Error:" + LTrim(Str(tnError)) + ':' + ; tcMethod + ':' + LTrim(Str(tnLine)) + ; " :" + laError[3]) ELSE This.AddError("VFP Error:"+LTrim(Str(tnError))+':'+tcMethod+':'+LTrim(Str(tnLine))) ENDIF ENDPROCTell you truth, we are using this class for a couple of years and never had an error on the .send. Most likely MAPI isn't installed or configured properly on your PC.
RETURN 0 >>* with >>RETURN This.nErrorsOr check o.geterrorcount() in addition to return value.
>>> >>>SET CLASSLIB TO mapimail.vcx additive >>> >>>o=CREATEOBJECT("cusmapi") >>> >>>lctext="This is the message to be sent by MAPI" >>>lcfile="mapimail.txt" >>> >>>lreturn = o.sendmail("SCHARNAS","asstcpa","chankey@f1tech.com","TEST",lctext,lcfile,.t.,.t.,.f.) >>> >>>RETURN "I AM DONE AND lreturn = "+STR(lreturn) >>> >>>