예제 #1
0
        private void Init()
        {
            logger = new Logger(this);
            listBoxAvancement.Items.Clear();
            listeAvancement = new List<string>();

            ThreadRenamer threadRenamer = new ThreadRenamer(this);
            thread = new Thread(new ThreadStart(threadRenamer.Work));
            thread.SetApartmentState(ApartmentState.STA);
            thread.Start();
        }
예제 #2
0
        private void btnLancer_Click(object sender, RoutedEventArgs e)
        {
            if(listBoxDossiers.Items.Count > 0)
            {
                logger = new Logger(this);
                listBoxAvancement.Items.Clear();
                listeAvancement = new List<string>();

                ThreadRenamer threadRenamer = new ThreadRenamer(this);
                thread = new Thread(new ThreadStart(threadRenamer.Work));
                thread.SetApartmentState(ApartmentState.STA);
                thread.Start();
            }
        }