Пример #1
0
        private void lvEmail_MouseDoubleClick(object sender, MouseEventArgs e)
        {
            if (lvEmail.SelectedIndices[0] != -1) //something is selected
            {
                if (Properties.Settings.Default.playSounds)
                    Sound.Click.Play();

                EmailForm webDesign = new EmailForm(EmailPurpose.Receive, Convert.ToInt32(lvEmail.SelectedItems[0].SubItems[4].Text));
                webDesign.Show();
            }
        }
Пример #2
0
        private void btnNew_Click(object sender, EventArgs e)
        {
            MemberList temp = new MemberList(true);
            switch(cbTo.SelectedIndex)
            {
                //To Individual Member
                case 0:
                    temp.ShowDialog();
                    //check if something was selected
                    if (ClsStorage.selectedMembersList.Count > 0)
                    {
                        if (Properties.Settings.Default.playSounds)
                            Sound.Click.Play();
                        EmailForm webDesign = new EmailForm(EmailPurpose.Send, -1, ClsStorage.selectedMembersList);
                        webDesign.ShowDialog();
                    }

                    break;
                //BCC Individual Member
                case 1:
                    temp.ShowDialog();
                    //check if something was selected
                    if (ClsStorage.selectedMembersList.Count > 0)
                    {
                        if (Properties.Settings.Default.playSounds)
                            Sound.Click.Play();
                        EmailForm webDesign = new EmailForm(EmailPurpose.Bcc, -1, ClsStorage.selectedMembersList);
                        webDesign.ShowDialog();
                    }
                    break;
                //all active members in current term
                case 2:
                    //clear the list
                    ClsStorage.selectedMembersList.Clear();

                    //now, add everyone in the term to it
                    for(int i = 0; i < ClsStorage.currentClub.listTerms[ClsStorage.currentClub.listTerms.Count-1].numMembers; i++)
                        if (!ClsStorage.currentClub.listTerms[ClsStorage.currentClub.listTerms.Count - 1].checkLimbo(i))
                            ClsStorage.selectedMembersList.Add(ClsStorage.currentClub.listTerms[ClsStorage.currentClub.listTerms.Count - 1].members[i]);

                    //check if something was selected
                    if (ClsStorage.selectedMembersList.Count > 0)
                    {
                        if (Properties.Settings.Default.playSounds)
                            Sound.Click.Play();
                        EmailForm webDesign = new EmailForm(EmailPurpose.Bcc, -1, ClsStorage.selectedMembersList);
                        webDesign.ShowDialog();
                    }

                    break;
                //all members in current term
                //similar idea to case 1 without the check
                case 3:
                    //clear the list
                    ClsStorage.selectedMembersList.Clear();

                    //now, add everyone in the term to it
                    for (int i = 0; i < ClsStorage.currentClub.listTerms[ClsStorage.currentClub.listTerms.Count - 1].numMembers; i++)
                        ClsStorage.selectedMembersList.Add(ClsStorage.currentClub.listTerms[ClsStorage.currentClub.listTerms.Count - 1].members[i]);

                    //check if something was selected
                    if (ClsStorage.selectedMembersList.Count > 0)
                    {
                        if (Properties.Settings.Default.playSounds)
                            Sound.Click.Play();
                        EmailForm webDesign = new EmailForm(EmailPurpose.Bcc, -1, ClsStorage.selectedMembersList);
                        webDesign.ShowDialog();
                    }

                    break;
                //To Entire Mailing List
                case 4:
                    //check if something was selected
                    if (Properties.Settings.Default.playSounds)
                        Sound.Click.Play();
                    EmailForm massEmailMaker = new EmailForm(EmailPurpose.MassEmail);
                    massEmailMaker.ShowDialog();
                    break;
            }
        }
Пример #3
0
        private void btnReply_Click(object sender, EventArgs e)
        {
            if (Properties.Settings.Default.playSounds)
                Sound.Click.Play();

            EmailForm webDesign = new EmailForm(EmailPurpose.Reply, messageIndex, fromIndexList);
            webDesign.Show();
        }