The TransactFileToStream function allows the content of a client file to be transferred to a variant variable.
Syntax | |||||
TransactFileToStream(SourceFile, Data) | |||||
Return value | |||||
Type |
Description | ||||
Long |
0 if the function could be successfully executed. | ||||
Parameter | |||||
Use |
Name |
Type |
Passing |
Description | |
Required |
SourceFile |
String |
ByVal |
Path to the file whose contents are to be read. Wildcards are not allowed. Predefined directories are supported. | |
Required |
Data |
Variant |
ByRef |
Data of the file | |
SourceFile contains a path to the file whose contents are to be transferred to the server.
Note
The function supports predefined directories:
Begriff |
Description |
[TMPDIR] |
Current temp directory at the client or server The directory is often located in the user directory, e.g. C:\Users\Benutzer.Domäne\AppData\Local\Temp |
[APPDIR] |
The TCE program directory at the client or server, often C:\Program Files (x86)\TAP.CON\TCE |
[WINDIR] |
The Windows directory at the client or server, often C:\Windows |
[SYSDIR] |
The system directory at the client or server, often C:\Windows\System32 |
[APPDATADIR] |
The application data directory at the client or server, e.g. C:\Users\Benutzer.Domäne\AppData\Roaming |
[PROGDATADIR] |
The program data directory at the client or server, e.g. C:\ProgramData |
Return of the function is 0 on success or the error code of the transfer.