Le DataGridView est rempli et des qu'il y a cette action tous les items a l’intérieur disparaisse
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8 Private Sub lblIdIntervention_TextChanged(sender As System.Object, e As System.EventArgs) Handles lblIdIntervention.TextChanged If lblIdIntervention.Text <> "..." Then If DataGridListeDep.CurrentRow.Cells(7).Value.ToString() <> "" Then macnx.Se_Connecter_MySqlServer() TextBoxTempsIntervention.Text = macnx.Executer_Requete_TIMEDIFF_EnCour(lblIdIntervention.Text) macnx.Se_Deconnecter_MySqlServer() End If End Ifje pense que ça vient l'or de la requête mais je n'ai aucune certitude.
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11 Public Function Executer_Requete_TIMEDIFF_EnCour(id As String) As String Dim requete As String = "SELECT TIMEDIFF ( NOW() , DateHeureDebIntervention ) FROM date WHERE IdIntervention = " & id & " " Try Cmd.CommandText = requete Dim resutl As String = Cmd.ExecuteScalar().ToString() Return resutl Catch ex As Exception MessageBox.Show(ex.Message) End Try End Function
Merci d'avance pour votre aide .
Partager