Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7941023
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T23:32:23+00:00 2026-06-03T23:32:23+00:00

I am getting the following message in the chilkat exception calling ConnectSocket2 IPV6 enabled

  • 0

I am getting the following message in the chilkat exception

  calling ConnectSocket2
    IPV6 enabled connect with NO heartbeat.
    Cannot connect, hostname is zero length
    ConnectFailReason: 1
    Failed to connect to FTP server.
    Failed.   --ConnectOnly_Ftp2
--ChilkatLog

I am trying to connect to FTP server using chilkat’s Ftp2 class(using c#), using Connect method.

Following is my class which I am using to connect with the FTP2

   public class FTPClient
   {        
    private Ftp2 m_FtpInfo;

    const int FTP_DEFAULT_PORT = 21;

    public FTPClient()
    {
        m_FtpInfo = null;
    }

    public FTPClient(string userName, string password, string hostName, int port)
    {
        m_FtpInfo = new Ftp2();
        m_FtpInfo.Account = userName;
        m_FtpInfo.ClientIpAddress = hostName;
        m_FtpInfo.Password = password;
        //m_FtpInfo.Port = port;
    }

    public Ftp2 FTPInfo
    {
        get
        {
            if (m_FtpInfo == null)
                m_FtpInfo = new Ftp2();
            return m_FtpInfo;
        }
        set { m_FtpInfo = value; }
    }

    public void Connect()
    {
        lock (this)
        {
            if (m_FtpInfo == null)
            {
                m_FtpInfo = new Ftp2();
            }

            AppConfiguration appConfiguration = AppConfiguration.Instance;
            /*
             * Steps to connect to FTP site using Chilkat
             * 1. Unlock the component by passing the code provided by Chilkat
             * 2. Connect to the Site by specifying the hostname and port
             */

            // Unlock the component.
            if (!m_FtpInfo.UnlockComponent("AnythingWorksFor30DayTrial"))
            {
                throw new FTPConnectionExceptions(CommunicationError.UnlockFailed, m_FtpInfo.LastErrorText);
            }


            // Connect to the FTP server. (use a domain name or IP address)            
            if (!m_FtpInfo.Connect())
            {
                throw new FTPConnectionExceptions(CommunicationError.ConnectionFailed, m_FtpInfo.LastErrorText);
            }
        }
    }

    public void DisposeConnection()
    {
        lock (this)
        {
            if (m_FtpInfo == null) return;

            if (m_FtpInfo.IsConnected)
                m_FtpInfo.Disconnect();

            m_FtpInfo = null;
        }
    }

Can anyone please tell where am I going wrong?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T23:32:25+00:00Added an answer on June 3, 2026 at 11:32 pm

    The line m_FtpInfo.ClientIpAddress = hostName; isn’t required. The actual host to connect to isn’t set.

    Edit:

    The Chilkat example page sets the hostname like this:

    ftp.Hostname = "ftp.chilkatsoft.com";
    

    So instead of setting ClientIpAddress (the local PC’s ip), use Hostname.

    Edit 2:

    Try this:

    public FTPClient(string userName, string password, string hostName, int port)
    {
        m_FtpInfo = new Ftp2();
        m_FtpInfo.Account = userName;
        m_FtpInfo.Hostname = hostName;
        m_FtpInfo.Password = password;
        //m_FtpInfo.Port = port;
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Am getting following error message on calling WCF service: The formatter threw an exception
I have enabled NSZombie's and I am getting the following message in my console
I am getting the following message while installing my application: You cannot start application
I am getting the following message when calling RingTonePreference on Samsung Galaxy (everything works
We are getting following error message in one Windows XP - X86 Exception Source:
I'm getting the following exception message: javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path validation failed: java.security.cert.CertPathValidatorException: algorithm
I am getting following error message when using Doctrine ORM in Codeigniter. ( !
I'm getting the following message in my users' crash logs: Dyld Error Message: Symbol
Per the code below, I am getting the following message. I am fairly certain
I'm getting the following error message and I can't seem to figure out the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.