Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Amyuni SendMail problem
Message
 
To
All
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Title:
Amyuni SendMail problem
Miscellaneous
Thread ID:
00723897
Message ID:
00723897
Views:
56
Hi,

We're using the Amyuni PDF converter to generate PDF files. We can generate the PDF files with no problems except when we do a SendMail() call (which is an internal method/procedure from within the PDF converter.

Further printing/generation of PDF files stalls after we call SendMail(). The list of printers just says 'Error printing ...'.

Here the code I'm running:
PRIVATE fcFileName, fcFileAlias

WAIT WINDOW "Creating E-mail attachment..." NOWAIT NOCLEAR

** oPDF was created and initialized in the beginning of the app
IF VARTYPE(oPDF) = "O"
**Set output file name
fcFileName = JUSTPATH(SET("DEFAULT") + CURDIR()) + "MSRTEMP.PDF"
oPDF.DefaultFileName = fcFileName

** Specify the file options
oPDF.FileNameOptions = 1+2

LOCATE &&Go Top
fcFileAlias = ALLTRIM(cReport) + "-" + ALLTRIM(CC_INFO.cRefNo) + ".PDF"

** Print the Document into the Amyuni PDF printer driver
SET PRINTER TO NAME "Amyuni PDF Converter"
IF PRINTSTATUS()
REPORT FORM &cReport RANGE &cRange TO PRINTER NOEJECT NOCONSOLE

** Reset to default printer
SET PRINTER TO DEFAULT

** SendMail format: TO, CC, BCC, Subject, Message, Attached, Options
oPDF.SendMail("", "", "", "", "", fcFileName + ";" + fcFileAlias, 2)

WAIT WINDOW "E-mail sent" NOWAIT
ELSE
= MESSAGEBOX("PDF driver not ready", 0+16+0, "PDF Creation")
ENDIF
ELSE
WAIT CLEAR
** Amyuni PDF Driver not loaded
= MESSAGEBOX(oPDF.GetLastErrorMsg(), 0+16+0, "E-Mail Document")
ENDIF

Any help is greatly appreciated.

Thanks,
Arriyel
Speak using soft and sweet words in case you have to eat them later.
Reply
Map
View

Click here to load this message in the networking platform