fat controller
Slightly round the bend..
- Local time
- Today, 00:43
- Joined
- Apr 14, 2011
- Messages
- 758
Is there a way to have VBA code return the data values from the same field on more than one record?
Essentially, I have a system whereby a vehicle is allocated a number (RunNumber), and for the most part the vehicle will remain allocated to that number from the start of the day to the end, however there are times where it will be de-allocated (handled by a radio button), and then allocated another number - there is the potential for this to happen three or maybe four times in extreme circumstances. Each allocation of a run is a separate record.
Each vehicle has a unique ID of its own, and I already have a query that will return all the records for the specified date range and show all Run Numbers that vehicle had been allocated to - however, I am wanting to incorporate the answer with a sequence of other checks in a bit of VBA, and have the answer to all those checks (variables) returned on a form.
If a vehicle has been allocated to run 10, 192 and 56 during the course of the day, I am looking for that information to be displayed to the user, something along the lines of:
"Today, this vehicle has been allocated to runs: 10, 192, 56" - what would I need to do with code to get that sort of return?
Essentially, I have a system whereby a vehicle is allocated a number (RunNumber), and for the most part the vehicle will remain allocated to that number from the start of the day to the end, however there are times where it will be de-allocated (handled by a radio button), and then allocated another number - there is the potential for this to happen three or maybe four times in extreme circumstances. Each allocation of a run is a separate record.
Each vehicle has a unique ID of its own, and I already have a query that will return all the records for the specified date range and show all Run Numbers that vehicle had been allocated to - however, I am wanting to incorporate the answer with a sequence of other checks in a bit of VBA, and have the answer to all those checks (variables) returned on a form.
If a vehicle has been allocated to run 10, 192 and 56 during the course of the day, I am looking for that information to be displayed to the user, something along the lines of:
"Today, this vehicle has been allocated to runs: 10, 192, 56" - what would I need to do with code to get that sort of return?