ftp upload objective c
===

I'm looking to upload a plist file or a small pic to an FTP using objective-C. I've looked at SimpleFTP and others. I want to accomplish a simple ftp upload like in this C# example below, can someone share such a download example using Objective-C ? Thanks....




 private void Upload(string filename)
    {
        FileInfo fi = new FileInfo(filename);

        FtpWebRequest ftp = (FtpWebRequest)FtpWebRequest.Create("ftp://" + textBox1.Text + "/" + Path.GetFileName(filename));
        ftp.Credentials = new NetworkCredential(textBox2.Text, textBox3.Text);
        ftp.Method = WebRequestMethods.Ftp.UploadFile;
        ftp.UseBinary = true;
        ftp.KeepAlive = false;
        ftp.ContentLength = fi.Length;

        // The buffer size is set to 20kb
        int buffLength = 20480;
        byte[] buff = new byte[buffLength];
        int contentLen;

        //int totalReadBytesCount = 0;

        FileStream fs = fi.OpenRead();

        try
        {
            // Stream to which the file to be upload is written
            Stream strm = ftp.GetRequestStream();

            // Read from the file stream 2kb at a time
            contentLen = fs.Read(buff, 0, buffLength);

            // Till Stream content ends
            while (contentLen != 0)
            {
                // Write Content from the file stream to the 
                // FTP Upload Stream
                strm.Write(buff, 0, contentLen);
                contentLen = fs.Read(buff, 0, buffLength);
            }

            // Close the file stream and the Request Stream
            strm.Close();
            fs.Close();

        }
        catch (Exception ex)
        {
            MessageBox.Show(ex.Message, "Upload Error");
        }
    }