CREPORTUPLOAD¶
Allows for the uploading of files, into CALUMO, for any custom purposes.
CReportUpload files are saved to a dedicated database table, ie not uploaded to the CALUMO tree.
CReportUpload functions only in web reports. In Excel, a simple textual confirmation of the existence of the formula is displayed
A stored procedure (proc) can be run after the file is uploaded (if configured) and is passed various arguments from the formula - the purpose of the proc is to allow the report author to do something with the uploaded file
Only one file can be uploaded per formula. If more than one is selected by the report user, only the first is uploaded
Storage¶
The parameters loginID, fileKey, fileID (DB ID of the record) and jobID (a GUID for this event in the format “jobid-{GUID}”) are always passed to the proc, and custom parameters (specified in the ProcArgs argument of the formula) are then appended
The data table (ReportUploadFile) stores the DateUploaded, FileByteCount, FileBytes, FileName and LoginID of user uploading the file and the file Key
Syntax
CREPORTUPLOAD (ButtonText, Key, ProcDataSource, ProcName, ProcArgs, ResultCell, AutoCalc, Enabled, ImageUrl)
Arguments¶
ButtonText : string
(required)¶
Text to appear on the upload button.
Key : string
(required)¶
A key (presumably unique) passed to the proc, to enable the report author to identify this upload event.
ProcDataSource : string
¶
Datasource for a proc to run, once the file is uploaded.
ProcName : string
¶
Name of a proc to run.
ProcArgs : string
¶
Arguments to be passed to the proc - uses a special format, identical to CEXECSTOREDPROC, eg “@param1=’Hello’,@param2=’world’, @ID=22”
ResultCell : string
(required)¶
The cell in which to put the jobID (a GUID) if the file is successfully uploaded. This cell needs to be a visible cell if you want to use the jobID.
AutoCalc : boolean
¶
Whether to automatically calculate after the file upload is complete.
Default value: true
Enabled : boolean
¶
Enable or disable this formula. This simply provides a way of disabling the formula without having to remove it.
Default value: true
ImageUrl : string
¶
Image URL to display on this cell.
Examples¶
=CREPORTUPLOAD("Upload","unique-1","datasource1","myproc","@param1='Hello',@param2='world'",B9,FALSE,TRUE)