Hi Experts,
I have two Access tables: myTable and RefTable
In RefTable, I have two fields: From, To which hold number values. E.g.
From To
0 3
4 8
9 16
In myTable, I have a field: Brackets
Now I want to set the row source of this field to such that it contains a value list like:
0~3
4~8
9~16
>16
Values in RefTable may change and I want the values in myTable.Brackets to change accordingly. E.g.
RefTable myTable
========= ==========
From To value list in Brackets:
0 5 <=> 0~5
6 17 6~17
>17
Can anyone help provide VBA codes for such purpose?
strSQL = "INSERT INTO myTable(Brackets) SELECT '>' & Max([To]) FROM RefTable"
db.execute strSQL, dbFailOnError 'Add the greater than bit