CFtpServer::DeleteVirtualUser Method  
 
BOOL DeleteVirtualUser(
  UINT nHostId,  
  LPCTSTR lpszUserName  
);

Remove a virtual user from the specified host.

Parameters

nHostId
An integer value which identifies the virtual host. This parameter is reserved for future use and must always have a value of zero.
lpszUserName
A pointer to a string which specifies the user that will be removed. This parameter cannot be a NULL pointer or an empty string.

Return Value

If the method succeeds, the return value is non-zero. If the virtual host ID does not specify a valid host, the method will return zero. If the method fails, the last error code will be updated to indicate the cause of the failure.

Remarks

This method removes a virtual user that was created by a previous call to the AddVirtualUser method. This method will not match partial usernames and wildcard characters cannot be used to delete multiple users. Usernames are not case sensitive. You cannot use this method to delete the "anonymous" user.

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: csftsv10.lib
Unicode: Implemented as Unicode and ANSI versions.

See Also

AddVirtualUser