/// <summary>
        /// Changes the current FTP working directory to the specified path.
        /// </summary>
        /// <exception cref="FtpException">If the directory does not exist on the FTP server.</exception>
        /// <param name="directory">A <see cref="String"/> representing the file path of the directory.</param>
        public void SetCurrentDirectory(string directory)
        {
            int ret = WININET.FtpSetCurrentDirectory(
                _hConnect,
                directory);

            if (ret == 0)
            {
                Error();
            }
        }