示例#1
0
        protected void btnGuardar_Click(object sender, EventArgs e)
        {
            String   aviso      = ddlAviso.SelectedValue;
            DateTime fechaAviso = Convert.ToDateTime(convertirAFechaAmericana(txbFechaAviso.Text));

            try
            {
                if (bdTS.avsNuevoAviso(S, F, area, aviso, fechaAviso.ToString("MM/dd/yyyy HH:mm:ss"), U))
                {
                    llenarGdvAvisos();
                    prepararPnlNuevoAviso();
                    mst.mostrarMsjNtf(dic.msjSeHaIngresado);
                }
                else
                {
                    if (L.Equals("es"))
                    {
                        mst.mostrarMsjAdvNtf("Una familia solo puede tener un aviso de cada tipo.");
                    }
                    else
                    {
                        mst.mostrarMsjAdvNtf("A family can only have one warning of each type.");
                    }
                }
            }
            catch (Exception ex)
            {
                mst.mostrarMsjMdl(dic.msjNoSeRealizoExcp + ex.Message.ToString() + ".");
            }
        }