Ejemplo n.º 1
0
        private void btnAddAccs_Click(object sender, EventArgs e)
        {
            var ofd = new OpenFileDialog();

            if (ofd.ShowDialog() != DialogResult.OK)
            {
                return;
            }
            try
            {
                if (ofd.FileName != null)
                {
                    var accsCount = mainWorker.LoadAccounts(ofd.FileName);
                    lblAccountsCount.Text = accsCount.ToString();
                }
            }
            catch (Exception ex)
            {
                MessageBox.Show("Произошла ошибка: " + ex.Message);
            }
        }