Dear readers
I have in my form a recordsource containing several columns with nearly identical names
DR01, DR02, DR03 etc. How can I use this dynamically in VBA with a counter?
So when it is a field on the form, one can use
for counter = 1 to 10
ME(“DR0” & counter)
Next counter
But what analogy can I use when the data is not a form field but only part of the recordsource?
For single columns I use
me![DR01]
But is there a trick to use the counter with this as well?
ME![ DR0 & counter] does not work.
Many thanks
Ben
I have in my form a recordsource containing several columns with nearly identical names
DR01, DR02, DR03 etc. How can I use this dynamically in VBA with a counter?
So when it is a field on the form, one can use
for counter = 1 to 10
ME(“DR0” & counter)
Next counter
But what analogy can I use when the data is not a form field but only part of the recordsource?
For single columns I use
me![DR01]
But is there a trick to use the counter with this as well?
ME![ DR0 & counter] does not work.
Many thanks
Ben