Summary
How it works
Crystal Reports
Date
COPY_ARRAY
IS_WEEKEND
Decimal
COPY_ARRAY
Development
LINK_OPEN
VALIDATE
VALIDATE_TRANSACTION
VIEW_SCREEN
Integer
COPY_ARRAY
Short Integer
COPY_ARRAY
File
CREATE_DIRECTORY
CSV_TO_XLSX
DEL_DIRECTORY
DOWNLOAD
GET_COMPLETE_NAME
GET_EXTENSION
GET_HASH
GET_NAME
LIST_DIRECTORIES
LIST_FILES
PATH_TO_VOLUME
UNZIP
UPLOAD
VOLUME_TO_PATH
ZIP
FTP
DELETE
DOWNLOAD
LIST
UPLOAD
Image
GENERATE_CODE
IMAP
LIST_DIRECTORIES
JSON
COUNT
DEL_KEY
GET_KEYS
GET_ONE
GET_POS_KEY
GET_TYPE
GET_VALUE
SET_VALUE
TO_ARRAY
SMS
SEND
SMTP
SEND_EMAIL
Stock
GET_AVAILABLE_QTY
GET_COST
Text
COPY_ARRAY
COUNT_OCCURRENCES
HTML_DECODE
HTML_ENCODE
HTML_TO_TXT
IS_NUMERIC
LINK_DECODE
LINK_ENCODE
RANDOM
REPLACE
RTF_TO_TXT
SPLIT
TO_BASE64
User
CHECK_PASSWORD
Sale
CLOSE_ORDER
GET_PRICE
func X3.EN_CRYSTAL_PRINT(Char REPORT_IN, Char LANGUAGE_IN, Integer FORMAT_IN, Clbfile PATH_IN, Char() PARAM_TAB_IN, Char() VALUE_TAB_IN) : Tinyint
Starts a Crystal Reports print to a file on the server
- REPORT_IN Char X3 report code to print
- LANGUAGE_IN Char Language for printing
- FORMAT_IN Integer Format of the file to generate:
- 3 Word for Windows (*.doc)
- 5 Rich Text (*.rtf)
- 9 ASCII text
- 10 Paginated ASCII text
- 27 Microsoft Excel 97-2000 (*.xls)
- 28 Microsoft Excel 97-2000 (extended) (*.xls)
- 29 Adobe Acrobat (*.pdf)
- 31 Microsoft Excel Workbook (extended) (*xlsx)
- PATH_IN Clbfile Full path or volume to the file to generate
- PARAM_TAB_IN Char() Array of parameters as defined in the report
- VALUE_TAB_IN Char() Array of parameter values
Example
Launches the standard invoice report on an invoice number, in the current language and saves it in PDF in the tmp directory of the folder
Local Char TBPAR(30)(25)
Local Char TBVAL(60)(25)
Local Shortint NB
[L]NB=1
[L]TBPAR([L]NB) = "facturedeb" : [L]TBVAL([L]NB) = "ZAINV1404ZA011000004" : [L]NB+=1
[L]TBPAR([L]NB) = "facturefin" : [L]TBVAL([L]NB) = "ZAINV1404ZA011000004" : [L]NB+=1
[L]TBPAR([L]NB) = "codimp" : [L]TBVAL([L]NB) = "2" : [L]NB+=1
If func X3.EN_CRYSTAL_PRINT("SBONFACP", [V]GLANGUE, 29, filpath("tmp","report","pdf"), [L]TBPAR, [L]TBVAL)
Infbox "File created"
Else
Infbox "Error="+[V]GX3ERR
Endif