Question: how to check if file exists on ftp c#?
Answer: private bool CheckIfFileExistsOnServer(string fileName)
{
request. Credentials = new NetworkCredential("username", "password");
request. Method = WebRequestMethods. Ftp. GetFileSize;
try.
{
FtpWebResponse response = (FtpWebResponse)request. GetResponse();
return true;