title: MS Access Macro to count records matching multiple criteria
body: <p>I have a table of Issues and Actions, in a one-to-many relationship.</p>
  
  <p>I have a form OIssues, which allows the user to browse through each issue. It has an embedded subform which shows the actions associated with that issue, and there are command buttons which execute macros allowing the user to quickly add actions to the subform.</p>
  
  <p>However I want to be able to prompt the user if they try to add an action which already exists for that issue.</p>
  
  <p>Therefore I think I need to add VBA to the command button click which checks to see how many records exist for IssueID 1234 and are of the type "change request". If this is more than 1, prompt the user. However I can't find the correct command to do it!</p>
  
  <p>Any help greatly appreciated.</p>