private async void GetApplicationEventsJsonButton_Click(object sender, EventArgs e)
        {
            JsonTimeTextBox.Text = "";
            GetApplicationEventsJsonButton.Enabled = false;

            if (!Properties.Settings.Default.DonotShowAgain)
            {
                MessageBox.Show("This may take awhile, feel free to run other operations while waiting.");
                Properties.Settings.Default.DonotShowAgain = true;
                Properties.Settings.Default.Save();
            }


            try
            {
                StopWatcher.Instance.Start();
                var serviceItems = await PowerShellOperations1.GetApplicationEventsAsJson();

                JsonTimeTextBox.Text = $"{StopWatcher.Instance.ElapsedFormatted}";

                var f = new EventsForm(serviceItems);

                f.ShowDialog();
            }
            finally
            {
                GetApplicationEventsJsonButton.Enabled = true;
            }
        }
Esempio n. 2
0
        private void button4_Click(object sender, System.EventArgs e)
        {
            var form = new EventsForm();

            form.Show();
        }