예제 #1
0
        private void newEventLogToolStripMenuItem_Click(object sender, EventArgs e)
        {
            if (treeViewLogs.SelectedNode != null)
            {
                if (treeViewLogs.SelectedNode.Parent != null)
                {
                    // Pass in the machine name
                    NewEventLog log = new NewEventLog(treeViewLogs.SelectedNode.Parent.Text);

                    // Check if a log has actually been created
                    if (log.ShowDialog() == DialogResult.OK)
                    {
                        // Refresh the event logs under the machine
                        RefreshEventLogs(treeViewLogs.SelectedNode.Parent);
                    }
                }
            }
        }
예제 #2
0
        public void NewClicked()
        {
            if (treeViewLogs.SelectedNode != null)
            {
                if (treeViewLogs.SelectedNode.Parent != null)
                {
                    // Pass in the machine name
                    NewEventLog log = new NewEventLog(treeViewLogs.SelectedNode.Parent.Text);

                    // Check if a log has actually been created
                    if (log.ShowDialog() == DialogResult.OK)
                    {
                        // Refresh the event logs under the machine
                        RefreshEventLogs(treeViewLogs.SelectedNode.Parent);
                    }
                }
            }
        }