M
michelle
I'm trying to make a search in my database with a statement like this
magId = DMax("magasinId", "Photos", "[travelname] = '" & travel & "'"
And "[boxId] = highestBoxId")
pictureId and boxId are integers in the datadase and magasinId is a
string.
In the Sub they are all 'Variant'.
this works
magId = DMax("magasinId", "Photos", "[travelname] = '" & travel &
"'")
-but as soon I add an 'And' it doesn't
magId = DMax("magasinId", "Photos", "[travelname] = '" & travel & "'"
And "[boxId] = '" & highestBoxId & "'")
-nor des this
magId = DMax("magasinId", "Photos", "[travelname] = '" & travel & "'"
And "[boxId] = highestBoxId")
So,my conclusion is that I'm using the statement wrong when I add
the 'And'.
Can anyone help me?
Please
/Michelle
magId = DMax("magasinId", "Photos", "[travelname] = '" & travel & "'"
And "[boxId] = highestBoxId")
pictureId and boxId are integers in the datadase and magasinId is a
string.
In the Sub they are all 'Variant'.
this works
magId = DMax("magasinId", "Photos", "[travelname] = '" & travel &
"'")
-but as soon I add an 'And' it doesn't
magId = DMax("magasinId", "Photos", "[travelname] = '" & travel & "'"
And "[boxId] = '" & highestBoxId & "'")
-nor des this
magId = DMax("magasinId", "Photos", "[travelname] = '" & travel & "'"
And "[boxId] = highestBoxId")
So,my conclusion is that I'm using the statement wrong when I add
the 'And'.
Can anyone help me?
Please
/Michelle