Salut! j'ai créé un champ textbox et incrémenter automatique lorsque click sur
adleni
Messages postés44Date d'inscriptionmardi 24 mai 2011StatutMembreDernière intervention26 mars 2014
-
27 mai 2011 à 05:12
adleni
Messages postés44Date d'inscriptionmardi 24 mai 2011StatutMembreDernière intervention26 mars 2014
-
27 mai 2011 à 18:23
Salut!
j'ai créé un champ textbox et incrémenter automatique lorsque click sur boutton Nouveau
mais mon problème lorsque clique plusieurs fois el affiche : erreur non spécifie
ce code:
private void button1_Click(object sender, EventArgs e)
{ for (int i = 0; i < 9999; i++)
{
string req = "select * from Client where Num_clt=" + i + " ";
connection conn = new connection();
OleDbConnection connverif = new OleDbConnection(conn.chaine);
connverif.Open();
OleDbCommand commande = new OleDbCommand(req, connverif);
OleDbDataReader dr = commande.ExecuteReader();
if (dr.Read() == false)
{
num_clt.Text =Convert.ToString(i);
return;
}
}
}
A voir également:
Salut! j'ai créé un champ textbox et incrémenter automatique lorsque click sur