Esempio n. 1
0
        private void PrintESHNDeclarationPartTwo(ESHNDeclarationPartTwo partTwoData)
        {
            ESHNDeclarationPartTwoPrinter declaration = new ESHNDeclarationPartTwoPrinter(partTwoData);

            declaration.PrintIntoPdf();

            if (RequiredSoftwareChecker.IsAdobeReaderInstalled())
            {
                PreviewESHNDeclarationForm ESHNDeclarationForm = new PreviewESHNDeclarationForm(Constants.CompletedESHNDeclarationPartTwoFullPath);
                ESHNDeclarationForm.ShowDialog();
            }
            else
            {
                MessageBox.Show("У вас не установлено программное обеспечение Adobe PDF Reader. Сейчас вы перейдете на страницу установки. Удостоверьтесь, что у вас есть подключение к интернету.", "Предупреждение");
                InstallAdobeForm installAdobeForm = new InstallAdobeForm();
                installAdobeForm.ShowDialog();
            }
        }
Esempio n. 2
0
        private void MainForm_Load(object sender, EventArgs e)
        {
            try
            {
                CheckDataBase();
            }
            catch (Exception)
            {
                Environment.Exit(1);
            }

            keyData = CheckLicense();

            AddAvailableINN();

            SetESHNDeclarationPartOneLimits();
            SetESHNDeclarationPartTwoLimits();

            semesterToLoad             = SemesterToLoad.BothSemesters;
            incomeAndExpenseTimePeriod = new IncomeAndExpenseTimePeriod(GetSelectedYear());

            UpdateIncomeAndExpenseDateIntervals();

            programLogic.incomeAndExpenseLogic.Load(incomeAndExpenseTimePeriod, GetSelectedINN());
            programLogic.commonAssetsLogic.Load(GetSelectedINN());

            //IncomeAndExpenseGridView.Columns[0].Width = 60;
            //IncomeAndExpenseGridView.Columns[1].Width = 80;
            //IncomeAndExpenseGridView.Columns[3].Width = 80;
            //IncomeAndExpenseGridView.Columns[4].Width = 80;

            saveBackupDialog.FileName = DateTime.Now.ToShortDateString();

            CheckSemesterButtonsState();
            UseOfPropertyDataGridView.DataSource = useOfProperty;
            RequiredSoftwareChecker.CheckApplicationShortcut();
        }