Hey, this is the situation. I have imported a table from Excel and
know i must edit the saldo in the corresponding records tbl_Lignes.
Impdata tbl_Lignes
...................... ...................
File_nr Product saldo Dos_nr Line_nr saldo
-------- -------- ------ ------- ------- -----
123456 1 10 123456 1 ..
2 70 2 ..
3 65 3 ..
123457 1 50 123457 1
123458 1 40 123458 1
2 20 2
I loop through the Imptable and want to search the similar File nr
with the corresponding product nr in the tbl_Lignes and this with a
Findfirst.
I have wrote this and gives no errors but he doesn't find the
corresponding record.
......
......
Do While Not rstImpdata.EOF
strSeek = ""
strSeekDos = rstImpdata![File_nr]
strSeek = "Dos_nr = '" & strSeekDos & "'"
If (strSeek = strVgl) Then
With rstLignes
strLnr = ""
strLnr = rstLignes![Line_nr]
strSeek1 = "Dossier_Id = '" & strSeek & "' AND Ligne_Num = '" & strLnr
& "'"
.FindFirst strSeek1
!!!'HE DOESN'T FIND FILE_NR 123456 WITH Product 1 IN tbl_Lignes!!!!
If .NoMatch Then
MsgBox "No Ligne found in tbl_Ligne for " & strSeek1 &
"."
Else
.Edit
rstLignes![saldo] = rstImpdata![saldo]
.Update
.MoveNext
End If
End With
Else
.....
.....
What is wrong?? I' don't know it anymore.