If the method succeeds, the return value is non-zero. If the
command is not recognized, the method will return zero. If the method
fails, the GetLastError method will return more information
about the last error that has occurred.
The EnableCommand method is used to enable access to a
specific command on the server. When a command is
enabled, it will also enable any corresponding feature related to
that command. For example, if the MDTM command is enabled and a
client issues the FEAT command to request a list of supported
features, the command will be included in the list. The
IsCommandEnabled method can be used to determine if a
command is enabled or not.
The command name provided to this method must match the commands
defined in RFC 959 or related protocol standards. It is important
to distinguish between commands recognized by an FTP server and the
commands that client programs may use. For example, the standard
Windows FTP command line program provides commands such as GET and PUT
to download and upload files. However, those are not the actual
commands sent to a server. Instead, the corresponding server commands
issued by a client application would bet RETR (retrieve) and STOR
(store). Refer to File
Transfer Protocol Commands for a complete list of server commands.