public override bool Buscar(int IdBuscado)
{
DataTable dt = new DataTable();
try
{
dt = conexion.ObtenerDatos(string.Format("select * from Personas where PersonaId=" + IdBuscado));
if (dt.Rows.Count > 0)
{
this.PersonaId = (int)dt.Rows[0]["PersonaId"];
this.Nombre = dt.Rows[0]["Nombre"].ToString();
}
}
catch (Exception ex)
{
throw ex;
}
return dt.Rows.Count > 0;
}