M
Muneer Mikel
Hi,
The following are a couple of lines from a code in my form:
Dim TableTemp As Integer
Dim varX As Variant
TableTemp = Int((100 - 1 + 1) * Rnd + 1)
varX = DLookup("[NoOfSeats]", "Thursday", "[TableNo] =!TableTemp")
The fields [NoOfSeats] and [TableNo] are from "Thursday" table. I found out
that when I run the code, the "varX" is Null. I believe that the way I refer
to "TableTemp" in the DLookup line is wrong!
I tried to use "&TableTemp", "TableTemp", etc. yet nothing worked.
Could you please tell me how can I refer to a temp variable on a form in
another table.
Thank you,
Muneer Mikel
The following are a couple of lines from a code in my form:
Dim TableTemp As Integer
Dim varX As Variant
TableTemp = Int((100 - 1 + 1) * Rnd + 1)
varX = DLookup("[NoOfSeats]", "Thursday", "[TableNo] =!TableTemp")
The fields [NoOfSeats] and [TableNo] are from "Thursday" table. I found out
that when I run the code, the "varX" is Null. I believe that the way I refer
to "TableTemp" in the DLookup line is wrong!
I tried to use "&TableTemp", "TableTemp", etc. yet nothing worked.
Could you please tell me how can I refer to a temp variable on a form in
another table.
Thank you,
Muneer Mikel