Hi everybody,
I have a non normalised set of data, where months of the year are field names, like [01-00], [02-00], meaning januari 2000, februari 2000. I want put these dates in a table as data. So i want to step through these field names and write them to a table. But i dont know how i can step through these field names, if i make myself clear. THis is some code:
So i can refer to a field in the recordset like:
rst![01-00]
But what can i use if i want it like this
rst!varMMYY, where varMMYY is changing all the time, stepping through all the months.
If is use this
varMMYY = CVar("[" & strZeroMonth & CStr(intMonth) & "-" & Right(intYear, 2) & "]")
varPeriodField = rst!varMMYY it causes an error, "item not found in this collection".
Pampers
Keeping it simple can be complicated
I have a non normalised set of data, where months of the year are field names, like [01-00], [02-00], meaning januari 2000, februari 2000. I want put these dates in a table as data. So i want to step through these field names and write them to a table. But i dont know how i can step through these field names, if i make myself clear. THis is some code:
So i can refer to a field in the recordset like:
rst![01-00]
But what can i use if i want it like this
rst!varMMYY, where varMMYY is changing all the time, stepping through all the months.
If is use this
varMMYY = CVar("[" & strZeroMonth & CStr(intMonth) & "-" & Right(intYear, 2) & "]")
varPeriodField = rst!varMMYY it causes an error, "item not found in this collection".
Pampers
Keeping it simple can be complicated