Ver Mensaje Individual
  #9 (permalink)  
Antiguo 15/04/2008, 21:23
ManuelV
 
Fecha de Ingreso: octubre-2003
Mensajes: 101
Antigüedad: 20 años, 7 meses
Puntos: 0
Re: C#: Validacion Existe? No existe?

private void txtProducto_Leave(object sender, System.EventArgs e)
{
DataSet ds = new DataSet();
ds = Helper.ObtenerDataTableGetS("[sp_comanda_valproducto]", txtProducto.Text);

if (ds.tables(0).rows.count == 0 )
{
MessageBox.Show("No existe!");
}
}

nota: Helper.ObtenerDataTableGetS, es mi clase para llamar SP

por ahi va...solo que me da estos errores:

Error 1 No se puede convertir implícitamente el tipo 'System.Data.DataTable' a 'System.Data.DataSet' C:\Proyectos Visual.NET\GesCas\GesCas\ComandaForm.cs 406 22 GesCas

Error 2 'System.Data.DataSet' no contiene una definición para 'tables' C:\Proyectos Visual.NET\GesCas\GesCas\ComandaForm.cs 408 28 GesCas



manuel

Última edición por ManuelV; 15/04/2008 a las 21:37