title: FtpClient storeFile always return False
body: <p>Please figure this out. The code runs properly without any exception.</p>
  <pre><code>try
  {
      FTPClient ftp = new FTPClient();
      ftp.connect(server);
      if(!ftp.login(username, password))
      {
          ftp.logout();
          return false;
      }
      int reply = ftp.getReplyCode();
      if (!FTPReply.isPositiveCompletion(reply))
      {
          ftp.disconnect();
          return false;
      }
      InputStream in = new FileInputStream(localfile);
      ftp.setFileType(ftp.BINARY_FILE_TYPE, ftp.BINARY_FILE_TYPE);
      ftp.setFileTransferMode(ftp.BINARY_FILE_TYPE);
      Store = ftp.storeFile(destinationfile, in);
      in.close();
      ftp.logout();
      ftp.disconnect();
  }
  catch (Exception ex)
  {
      ex.printStackTrace();
      return false;
  }
  return Store;
  </code></pre>
  <p>Butm the return statement always returns false and the file is not uploaded on the server. Someone please help on this.</p>
  <p>For your information, I am in an office network. ---&gt; do we need to add any proxies?</p>
  <hr />
  <pre><code>File file = new File(&quot;C:\\Users\\sg0214273\\Desktop\\seagate\\seagate.txt&quot;);
  FileInputStream input = new FileInputStream(file);
  client.setFileType(FTP.BINARY_FILE_TYPE);
  if (!client.storeFile(file.getName(), input)) {
    System.out.println(&quot;upload failed!&quot;);
  } 
  reply = client.getReplyCode();
  
  if(!FTPReply.isPositiveCompletion(reply)) {
    System.out.println(&quot;upload failed!&quot;);
  }
  </code></pre>
  <pre class="lang-none prettyprint-override"><code>Login success...
  230 User ******** logged in.
  upload failed!-----&gt; is form boolean return value of storefile 
  upload failed!---------&gt; is from replycode...
  Logout from FTP server...
  </code></pre>
  <p>Please help out.</p>