If you are getting above error while using FtpWebRequest method to upload file to a FTP sever, please check your URL, The URL must be case sensitive. Otherwise you will get this error.