Example #1
0
        public void GuardarEmpleado(int intUserId, string strNumCa, string strNombre, string strSexo, string strCedula, string strCorreoOficina, string strCiudad, string strTeleOficina,
                                    string strCorreoPersonal, string strTitulo, DateTime dtmFechaNacimiento, DateTime dtmFechaEmpleo, DateTime dtmFechaSalida, string strCodEmp, string strCelular,
                                    string strDireccion, int intTipoUsuario)
        {
            DataTable dtbAuditoria = new DataTable("Auditoria");

            ServicioProperTime.ServicioProperTimeClient objServicioProperTime;
            objServicioProperTime = new ServicioProperTime.ServicioProperTimeClient();
            try
            {
                objServicioProperTime.Open();
                objServicioProperTime.GuardarEmpleado(intUserId, strNumCa, strNombre, strSexo, strCedula, strCorreoOficina, strCiudad, strTeleOficina, strCorreoPersonal,
                                                      strTitulo, dtmFechaNacimiento, dtmFechaEmpleo, dtmFechaSalida, strCodEmp, strCelular, strDireccion, intTipoUsuario, dtbAuditoria);
            }
            catch (Exception ex)
            {
                throw ex;
            }
            finally
            {
                if (objServicioProperTime != null && objServicioProperTime.State == System.ServiceModel.CommunicationState.Opened)
                {
                    objServicioProperTime.Close();
                }
            }
        }