title: Display a record on subform based on form's combo box selection (using VBA)
body: <p>I have a main form, which has a combo box i've named <strong>FLRecCombo</strong>. This was originally set up so that selecting an option in the combo box would move to that record on the main form's record source.</p>
  <p>I then also had subforms on the main form, which when initially set up would move to their record in their record source based on whatever record source the main form was currently on using a common field (i.e. you could use the combo box to move to a given record on all subforms).</p>
  <p>Note how all this is in the past tense...</p>
  <p>I wanted to add some code to the <strong>FLRecCombo</strong> AfterUpdate event in VBA; unfortunately this seems to have cut the relationships between combo box, main form and subforms. I think possibly there was a macro created in the <strong>FLRecCombo</strong> AfterUpdate event, which I've brashly overwitten by going through the code builder.</p>
  <p>How might I reinstate the behaviour I initially had? I've tried a method that was suggested on this website; here's the object references:</p>
  <ul>
  <li>Subform name: <strong>Finance_FunderAllocation subform</strong></li>
  <li>Subform record source: <strong>Finance_HeadRec_FunderAllocation</strong></li>
  <li>Subform record source field name to match: <strong>Funding Line</strong></li>
  <li>Form record source field name to match: <strong>FundingLine</strong></li>
  </ul>
  <p>Here's the code that I tried:</p>
  <pre class="lang-vb prettyprint-override"><code>Private Sub FLRecCombo_AfterUpdate() 
  
      With Me.[Finance_FunderAllocation subform].Form.Recordset
          .FindFirst &quot;Funding Line=&quot; &amp; Me.FLRecCombo
      End With 
  
  End Sub
  </code></pre>
  <p>Access debugger doesn't like this though, saying:</p>
  <blockquote>
  <p>Run-time error '3077':</p>
  <p>Syntax error (missing operator) in expression.</p>
  </blockquote>
  <p>And then it highlights the line of code that starts <strong>.FindFirst</strong></p>
  <p>Any help would be much appreciated!</p>