コード例 #1
0
        private void emailButton_Click(object sender, EventArgs e)
        {
            var nodes      = ExtractClassNodes(_projectCont.Nodes);
            var dictionary = new Dictionary <string, string>();

            foreach (var nod in nodes)
            {
                //// get the file attributes for file or directory
                //FileAttributes attr = File.GetAttributes(ProjectCont.SelectedNode.Tag.ToString());
                dictionary[nod.Text] = nod.Tag.ToString();
            }

            var emailForm = new EmailForm(dictionary);

            emailForm.ShowDialog();
        }
コード例 #2
0
        private void emailTutorButton_Click(object sender, EventArgs e)
        {
            var nodes      = ExtractClassNodes(_projectCont.Nodes);
            var dictionary = new Dictionary <string, string>();

            foreach (var nod in nodes)
            {
                //// get the file attributes for file or directory
                //FileAttributes attr = File.GetAttributes(ProjectCont.SelectedNode.Tag.ToString());
                dictionary[nod.Text] = nod.Tag.ToString();
            }

            var emailForm = new EmailForm(dictionary)
            {
                titleLabel   = { Text = "Email your teacher" },
                descLabel    = { Text = "Use this form to quickly email your teacher and ask them for help. Just describe your problem and select the files you would like to attach for them to look at." },
                emailLabel   = { Text = "Teacher's email:" },
                emailTextBox = { Text = ProjectWindow.currentTutorEmail, Enabled = false }
            };

            emailForm.ShowDialog();
        }