RexOfNapa
New member
- Local time
- Today, 11:11
- Joined
- Jun 9, 2022
- Messages
- 5
78 years young, Like Databases Not a programmer. Have played with access vba a little.
Really need some help here
I have two tables called tblActivities the other tblInterests.
tblActivities has three fields [Activity] , [Activity ID] ,[Count] < count is a number field>
tblInterests has two fields [Activity ID], [Badge] <Both are number fields>
The Activity tblActivities is fixed at 100 records <Acitity like Golf, Bowling, Travel, ;;;;>
The Badge can be any number of records. (think membership)
I have vba code that loops thru tblInterests that counts how many times
Each activity occurs in the tblInterests. I use dcount to count how
Many times that activity occurs in tblInterests. Dcount counts To a variable called intMyCount < Dcount is in a loop while .not EOF>
What I need to do is as the loop counts each activity in tblInterests
is to put that count into the [Count] field in tblActivities
I can’t even think how to do this. As the loop counts the first activity lets say <golf >and has the count in a variable called intMyCount
I need update tblActivitys [golf ], [count] = intMyVariable] < if intMyCount is 45 then tblActivity [Golf] count would be 45
When the loop finishes tblActivities count field would have the count of how many members are interested in that activity.
Hope that makes since and thanks as I don’t know where to begin.
Any help would be great and thanks!!!!!
RexOfNapa
Really need some help here
I have two tables called tblActivities the other tblInterests.
tblActivities has three fields [Activity] , [Activity ID] ,[Count] < count is a number field>
tblInterests has two fields [Activity ID], [Badge] <Both are number fields>
The Activity tblActivities is fixed at 100 records <Acitity like Golf, Bowling, Travel, ;;;;>
The Badge can be any number of records. (think membership)
I have vba code that loops thru tblInterests that counts how many times
Each activity occurs in the tblInterests. I use dcount to count how
Many times that activity occurs in tblInterests. Dcount counts To a variable called intMyCount < Dcount is in a loop while .not EOF>
What I need to do is as the loop counts each activity in tblInterests
is to put that count into the [Count] field in tblActivities
I can’t even think how to do this. As the loop counts the first activity lets say <golf >and has the count in a variable called intMyCount
I need update tblActivitys [golf ], [count] = intMyVariable] < if intMyCount is 45 then tblActivity [Golf] count would be 45
When the loop finishes tblActivities count field would have the count of how many members are interested in that activity.
Hope that makes since and thanks as I don’t know where to begin.
Any help would be great and thanks!!!!!

RexOfNapa