Hi Richard and the guys. Little at a time i am watching the videos as i can. I need help with our callers, we get callers who call every day and some every other day. In my database as we get the call and type in the callers phone number I made a continuous form for all the phone numbers to be in. How can i type in the phone number and compare it to the other ones in the continous form and if that number is in our database 10 times then a pop up message box shows Frequent after typing in the number?
Scott Axton 36 days ago
Not trying to dodge the question but what did you try?
Like you and I have discussed previously, it is all just putting the pieces together.
Richard says, "He provides the Legos. It it up to you to put them together in the way that works for you."
Just break it down into the parts first, then build it up to what you want it to be. Write the steps you need to follow out in English then convert what you are doing to Access.
For the search part, a little bit of it depends on how you are storing the numbers - with or with out the dashes and parenthesis (555) 222-1234 or just the number - 5552221234 ?
How are your tables set up to store the numbers?
One field in a separate table with designation for type (home, cell, business) or do you have them in three different fields?
The counting part would be pretty easy to add into the searching part. First check out the DCount and even more extensively in Access Expert 29.
For setting the value of the field, wrap the DCount in an IIF Function.
So say that we call your field FFClub to identify they are frequent caller you could just set that to the result of your DCount
So psudo code:
FFClub = IIF DCount of the Phone >= 10, then FFClub = true otherwise FFClub = False.