private bool AddMail()
        {
            try
            {
                Registration_Mail Dialog = new Registration_Mail();

                DateTime DateCreate = DateTime.Now;
                Dialog.DataReg_TB.Text = DateCreate.ToShortDateString();

                if (Dialog.ShowDialog() == DialogResult.OK)
                {
                    Int64 Index = -1;

                    using (var Connect = new NpgsqlConnection(SystemArgs.DataBase.ToString()))
                    {
                        Connect.Open();

                        using (var Command = new NpgsqlCommand($"SELECT last_value FROM \"AllMail_ID_seq\"", Connect))
                        {
                            using (var Reader = Command.ExecuteReader())
                            {
                                while (Reader.Read())
                                {
                                    Index = Reader.GetInt64(0);
                                }
                            }
                        }
                    }

                    Mail Temp = new Mail(Index + 1, Dialog.Name_TB.Text, Dialog.MiddleName_TB.Text, Dialog.Surname_TB.Text, DateCreate, Dialog.AddressMail_TB.Text);

                    if (SystemArgs.Request.AddMail(Temp))
                    {
                        SystemArgs.Mails.Add(Temp); return(true);
                    }
                    else
                    {
                        return(false);
                    }
                }
                else
                {
                    return(false);
                }
            }
            catch (Exception E)
            {
                MessageBox.Show(E.Message, "Ошибка", MessageBoxButtons.OK, MessageBoxIcon.Error);
                return(false);
            }
        }
        private bool ChangeMail()
        {
            try
            {
                if (Mails_DGV.CurrentCell.RowIndex >= 0)
                {
                    Mail Temp = (Mail)View[Mails_DGV.CurrentCell.RowIndex];

                    Registration_Mail Dialog = new Registration_Mail();

                    Dialog.label1.Text = "Изменение адреса электронной почты";

                    Dialog.DataReg_TB.Text     = Temp.DateCreate.ToShortDateString();
                    Dialog.Name_TB.Text        = Temp.Name;
                    Dialog.MiddleName_TB.Text  = Temp.MiddleName;
                    Dialog.Surname_TB.Text     = Temp.Surname;
                    Dialog.AddressMail_TB.Text = Temp.MailAddress;

                    if (Dialog.ShowDialog() == DialogResult.OK)
                    {
                        Mail NewMail = new Mail(Temp.ID, Dialog.Name_TB.Text, Dialog.MiddleName_TB.Text, Dialog.Surname_TB.Text, Temp.DateCreate, Dialog.AddressMail_TB.Text);

                        if (SystemArgs.Request.ChangeMail(NewMail))
                        {
                            SystemArgs.Mails.Remove(Temp);
                            SystemArgs.Mails.Add(NewMail);

                            return(true);
                        }
                        else
                        {
                            return(false);
                        }
                    }
                    else
                    {
                        return(false);
                    }
                }
                else
                {
                    throw new Exception("Необходимо выбрать объект");
                }
            }
            catch (Exception E)
            {
                MessageBox.Show(E.Message, "Ошибка", MessageBoxButtons.OK, MessageBoxIcon.Error);
                return(false);
            }
        }