title: Filter on Subdatasheet
body: <p>In Access 2003, I have form with a a datasheet and an embedded subdatasheet. I would like to apply filters to both the main and sub datasheets. First, I build a filter string for the main datasheet <code>strWhere</code>, and one for the sub datasheet <code>sdsWhere</code>. Next, from the From object of the main datasheet, I set <code>.filter=strWhere</code>. Then, I set a filter on the subdatasheet's Form object. Basically:</p>
  
  <pre><code>With Me.Controls(dataSheetName).Form
                  .Filter = strWhere
                  .FilterOn = True
       With .Controls(subsheetname).Form
                  .Filter = sdsWhere
                  .FilterOn = True
       End with
  End with
  </code></pre>
  
  <p>The problem is that the subdatasheet is only filtered for the first record of the main datasheet. Looking at the RecordSet of the sub datasheet, it only contains the child records of the first record in the main datasheet. I cannot find the other records anywhere. </p>
  
  <p>I know that it should be possible to filter all subdatasheet records, because from the Access interface, placing the cursor in the desired value, and selecting Records>>Filter by Selection has the desired effect. (Except that records in the main form with have empty subdatasheets show, and I would like them to not show)</p>