Sending a File to a Network Drive Letter via OFCDBSND command
From Support
In version 1.1.x of the Office Integrator PC component, we have switched FTP Server components because of issues of files getting truncated during transfer. Mabry software was not able to fully resolve issues we were finding.
The QUOTE SITE DRIVE command no longer works correctly.
The new method would be to transfer a file to the default FTP directory and then run the FILECOPY or FILEMOVE command to move the file to a local file path.
The parameters for FILEMOVE are as follows
P1 - Opcode (FILEMOVE)
P2 - From PC file name (can use drive letter or UNC path names)
P3 - To PC file name (can use drive letter or UNC path names)
P4 - Replace option (0=no replace, 1=replace)
This example moves the file to a drive letter of E:
OFCDBSND RMTSYS('1.1.1.1') FILE(QIWS/QCUSTCDT) RMTFIL('/QCUSTCDT.TXT') USR(TEST) PWD(TEST) FORMAT(BINARY)
OFCRUNPC RMTSYS('1.1.1.1') CMD('FILEMOVE~C:\QCUSTCDT.TXT~E:\DOWNLOADS\QCUSTCDT.TXT~1') OPTION(*OTHER)
This example moves the file to a UNC destination of \\SERVERNAME\SHARE\DOWNLOADS
OFCDBSND RMTSYS('1.1.1.1') FILE(QIWS/QCUSTCDT) RMTFIL('/QCUSTCDT.TXT') USR(TEST) PWD(TEST) FORMAT(BINARY)
OFCRUNPC RMTSYS('1.1.1.1') CMD('FILEMOVE~C:\QCUSTCDT.TXT~\\SERVERNAME\SHARE\DOWNLOADS\QCUSTCDT.TXT~1') OPTION(*OTHER)
The parameters for FILECOPY are as follows
P1 - Opcode (FILECOPY)
P2 - From PC file name (can use drive letter or UNC path names)
P3 - To PC file name (can use drive letter or UNC path names)
P4 - Replace option (0=no replace, 1=replace)
This example copies the file to a drive letter of E:
OFCDBSND RMTSYS('1.1.1.1') FILE(QIWS/QCUSTCDT) RMTFIL('/QCUSTCDT.TXT') USR(TEST) PWD(TEST) FORMAT(BINARY)
OFCRUNPC RMTSYS('1.1.1.1') CMD('FILECOPY~C:\QCUSTCDT.TXT~E:\DOWNLOADS\QCUSTCDT.TXT~1') OPTION(*OTHER)
This example copies the file to a UNC destination of \\SERVERNAME\SHARE\DOWNLOADS
OFCDBSND RMTSYS('1.1.1.1') FILE(QIWS/QCUSTCDT) RMTFIL('/QCUSTCDT.TXT') USR(TEST) PWD(TEST) FORMAT(BINARY)
OFCRUNPC RMTSYS('1.1.1.1') CMD('FILECOPY~C:\QCUSTCDT.TXT~\\SERVERNAME\SHARE\DOWNLOADS\QCUSTCDT.TXT~1') OPTION(*OTHER)
The parameters for FILEDELETE are as follows
P1 - Opcode (FILEDELETE)
P2 - PC file name (can use drive letter or UNC path names)
This example deletes a file on the E: drive
OFCRUNPC RMTSYS('1.1.1.1') CMD('FILEDELETE~E:\DOWNLOADS\QCUSTCDT.TXT') OPTION(*OTHER)
This example deletes a UNC file via FILEDELETE
OFCRUNPC RMTSYS('1.1.1.1') CMD('FILEDELETE~\\SERVERNAME\SHARE\DOWNLOADS\QCUSTCDT.TXT') OPTION(*OTHER)
