1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
| provider2 = "Provider=Microsoft.ACE.OLEDB.12.0;Data Source ="
dataFile2 = Label9.Text
connString2 = provider2 & dataFile2
myConnection2.ConnectionString = connString2
For Each myrow2 In DataGridView1.Rows
If (myrow2.Cells(0).Value = True) Then
derniere_pièce = myrow2.Cells(2).Value
requete_select2 = "SELECT ........"
da2 = New OleDbDataAdapter(requete_select2, myConnection2)
da2.Fill(ds2)
nombre_pièce_aimprimer = nombre_pièce_aimprimer + 1
myrow2.Cells(2).Style.BackColor = Color.Pink
End If
Next
Dim view2 As New DataView(tables2(0))
Dim source2 As New BindingSource()
source2.DataSource = view2
DataGridView2.DataSource = view2
DataGridView2.Refresh() |
Partager