Пример #1
0
        private void openAllFormToolStripMenuItem_Click(object sender, EventArgs e)
        {
            // Close all opened form
            closeAllChildrenFormExcept(null, null);

            CriteriaForm criteriaForm = null;

            if (isFormOpened(typeof(CriteriaForm)) == null)
            {
                criteriaForm           = new CriteriaForm();
                criteriaForm.MdiParent = this;

                criteriaForm.StartPosition = FormStartPosition.Manual;
                criteriaForm.Location      = new Point(0, 0);
                criteriaForm.Show();
            }

            CriteriaRankingForm criteriaRankingForm = null;

            if (isFormOpened(typeof(CriteriaRankingForm)) == null)
            {
                criteriaRankingForm           = new CriteriaRankingForm();
                criteriaRankingForm.MdiParent = this;

                criteriaRankingForm.StartPosition = FormStartPosition.Manual;
                criteriaRankingForm.Location      = new Point(criteriaForm.Width, 0);
                criteriaRankingForm.Show();
            }

            AlternativeListForm alternativeListForm = null;

            if (isFormOpened(typeof(AlternativeListForm)) == null)
            {
                alternativeListForm           = new AlternativeListForm();
                alternativeListForm.MdiParent = this;

                alternativeListForm.StartPosition = FormStartPosition.Manual;
                alternativeListForm.Location      = new Point(0, criteriaForm.Height);
                alternativeListForm.Show();
            }

            int        countAlternative = alternativeListController.getAlternativeList(currentTopic.topicId.ToString()).Count;
            ResultForm resultForm       = null;

            if (isFormOpened(typeof(ResultForm)) == null && countAlternative >= 2)
            {
                resultForm           = new ResultForm();
                resultForm.MdiParent = this;

                resultForm.StartPosition = FormStartPosition.Manual;
                resultForm.Location      = new Point(alternativeListForm.Width, criteriaForm.Height);
                resultForm.Show();
            }
        }
Пример #2
0
        private void criteriaListToolStripMenuItem1_Click(object sender, EventArgs e)
        {
            CriteriaForm criteriaForm = null;

            if (isFormOpened(typeof(CriteriaForm)) == null)
            {
                criteriaForm           = new CriteriaForm();
                criteriaForm.MdiParent = this;
                criteriaForm.Show();
            }
        }