コード例 #1
0
ファイル: TestsForm.cs プロジェクト: kong8313/MyPrograms
        public TestsForm(ClassForm classForm, PupilsForm pupilsForm, AnxietyTestResultMaker anxietyTestResultMaker, int pupilId, TestResultEngine testResultEngine, string name)
        {
            InitializeComponent();

            _classForm              = classForm;
            _pupilsForm             = pupilsForm;
            _anxietyTestResultMaker = anxietyTestResultMaker;
            _testResultEngine       = testResultEngine;
            _pupilId = pupilId;

            labelInfo.Text = "Ученик: " + name;
            printDocument1.DefaultPageSettings.Margins = new Margins(40, 40, 40, 40);
        }
コード例 #2
0
        private void ShowPupilsForm(int classId, string className)
        {
            if (_pupilsForm != null && !_pupilsForm.IsDisposed)
            {
                _pupilsForm.Close();
            }

            _pupilsForm = new PupilsForm(_mainForm, this, _anxietyTestResultMaker, classId, _pupilEngine, _testResultEngine, className)
            {
                MdiParent = _mainForm,
                Location  = new Point(470, 50)
            };
            _pupilsForm.Show();
        }