Beispiel #1
0
        public transporter()
        {
            //
            // TODO: Add constructor logic here
            //
            config			= new AirlockConfig.Config();
            config.readConfig();
            if (config.targetPath.Length <= 0) throw new ConfigException();

            tea				= new transportEventArgs();
            item			= new string[MAXITEM];
            itemCount		= 0;
            targetRoot		= config.targetPath + "\\" + System.Net.Dns.GetHostName() + "\\";

            deleteAfterCopy	= false;
        }
Beispiel #2
0
 private void subItemDetermined(object sender, transportEventArgs e)
 {
     setFile(e.info);
     progMain.Maximum = e.max;
     progMain.Value = e.pos;
     this.Show();
     Application.DoEvents();
 }
Beispiel #3
0
        private void itemAnalysed(object sender, transportEventArgs e)
        {
            setFile(e.info);
            progMain.Maximum = e.max;
            progMain.Value = e.pos;
            this.Show();
            Application.DoEvents();

            if (e.max == e.pos)
            {
                try
                {
                    setStatus("Determining subitems...");
                    myTransporter.determineSubItems();

                    setStatus("Copying items...");
                    myTransporter.copyAllItems();

                    setStatus("Complete!");
                    timClose.Enabled = true;
                }
                catch(Exception ex)
                {
                    setFile(ex.ToString());
                }
            }
        }