Exemple #1
0
        public bool ValidRazonSocial(string prm_RazonSocial, ref string p_Codi_personaExist, ref string p_Name_personaExist)
        {
            int codigoRetorno = -1;

            try
            {
                using (_DBMLPersonasDataContext SQLDC = new _DBMLPersonasDataContext(conexion))
                {
                    SQLDC.omgc_P_Persona_Valida
                    (
                        prm_RazonSocial,
                        ref p_Codi_personaExist,
                        ref p_Name_personaExist
                    );
                }
                if (p_Codi_personaExist == null)
                {
                    codigoRetorno = 1;
                }
            }
            catch (Exception ex)
            {
                throw ex;
            }
            return(codigoRetorno == 0 ? true : false);
        }