private void bGonder_Click(object sender, EventArgs e)
        {
            if (liste.SelectedIndex == -1)
            {
                return;
            }

            string dsy = liste.Text;

            AdresKayit ak;

            for (int i = 0; i < liste.CheckedItems.Count; i++)
            {
                dsy = liste.CheckedItems[i].ToString();
                ak  = new AdresKayit(dsy, yol);
                ak.Yukle();

                for (int j = 0; j < ak.Dosyalar.Length; j++)
                {
                    string KaynakDosya = ak.Dosyalar[j].ToString();
                    string HedefURL    = ak.Adres1 + "//" + Path.GetFileName(KaynakDosya);
                    GonderFtp(KaynakDosya, HedefURL, ak.User1, ak.Pass1);
                }
            }
        }
Ejemplo n.º 2
0
        void Duzenle(string gelen)
        {
            string dsy = gelen;

            AdresKayit ak = new AdresKayit(dsy, yol);

            ak.Yukle();

            tDosya.Text = gelen;
            tAdres.Text = ak.Adres1;
            tUser.Text  = ak.User1;
            tPass.Text  = ak.Pass1;

            for (int i = 0; i < ak.Dosyalar.Length; i++)
            {
                dosyalar.Items.Add(ak.Dosyalar[i]);
            }
        }
Ejemplo n.º 3
0
        private void button6_Click(object sender, EventArgs e)
        {
            string adr = "";

            if (tDosya.Text.IndexOf(".") > 0)
            {
                tDosya.Text = tDosya.Text.Substring(0, tDosya.Text.IndexOf("."));
            }

            adr = tDosya.Text + ".adrl";
            string yol = Application.StartupPath + "\\adresler";

            if (!Directory.Exists(yol))
            {
                Directory.CreateDirectory(yol);
            }
            AdresKayit ak = new AdresKayit(adr, yol);

            ak.Adres1 = tAdres.Text.Trim();
            ak.User1  = tUser.Text.Trim();
            ak.Pass1  = tPass.Text.Trim();

            ArrayList gd = new ArrayList();

            gd.AddRange(GonDosyalar);

            if (dosyalar.Items.Count > 0)
            {
                foreach (string str in dosyalar.Items)
                {
                    ak.GonDos1 += str + ",";
                }
            }
            if (ak.GonDos1.EndsWith(","))
            {
                ak.GonDos1 = ak.GonDos1.Remove(ak.GonDos1.Length - 1, 1);
            }

            ak.Kaydet();

            MessageBox.Show(ak.Yazildi.ToString());
        }
        void yukle()
        {
            if (liste.SelectedIndex == -1)
            {
                return;
            }
            string dsy = liste.Text;

            adresler.Items.Clear();

            AdresKayit ak = new AdresKayit(dsy, yol);

            ak.Yukle();
            adresler.Items.Add(ak.Adres1);

            for (int i = 0; i < ak.Dosyalar.Length; i++)
            {
                dosyalar.Items.Add(ak.Dosyalar[i]);
            }
        }