INT SetFileMode( |
|
UINT nMode |
|
); |
The SetFileMode method sets the default file transfer mode
for the current client session.
Parameters
- nMode
- Specifies the default type of data transfer mode for files
being opened or created on the server. This parameter can be
one of the following values.
Value |
Description |
FILE_MODE_STREAM |
The data is transmitted as a stream of bytes. This is the
default client transfer mode. |
FILE_MODE_BLOCK |
The data is transmitted as a series of data blocks
preceded by one or more header bytes. This transfer mode is
currently not supported. |
FILE_MODE_COMPRESSED |
The data is transmitted in compressed form. This transfer
mode is currently not supported. |
Return Value
If the method succeeds, the return value is the server result
code. If the method fails, the return value is FTP_ERROR. To get
extended error information, call GetLastError.
Remarks
The file transfer mode should be set before a file is opened or
created on the server. Once the transfer mode is set, it is in
effect for all files that are subsequently opened or created.
Requirements
Minimum Desktop Platform: Windows 7 (Service Pack 1)
Minimum Server Platform: Windows Server 2008 R2 (Service Pack 1)
Header File: cstools10.h
Import Library: csftpv10.lib
Unicode: Implemented as Unicode and ANSI versions.
See Also
OpenFile,
SetFileStructure,
SetFileType,
SetPassiveMode
|