title: pass parameter to crystal report
body: <p>I write this code but it have this error. </p>
  
  <blockquote>
    <p>"Run-time error '20553': Invalid parameter field name"</p>
  </blockquote>
  
  <p>can anyone help me to solve it?</p>
  
  <pre class="lang-vb prettyprint-override"><code>With CR
  
    .ParameterFields(0) = "start;" + CStr(Form1.cmbMonth.Text) &amp; ";True"
    .ParameterFields(1) = "end;" + CStr(Form1.cmbYear.Text) &amp; ";True"
  
    .ReportFileName = App.Path &amp; "\Report\Report1.rpt"
  
    .SelectionFormula = "{SW.dtaMonth}&gt;=date('" &amp; Format(Form1.cmbMonth.Text) &amp; "') and {SW.dtaYear}&lt;=date(" &amp; Format(Form1.cmbYear.Text) &amp; ")"
  
    .WindowTitle = "PG Variable Overhead Report" 'title of report
    .Action = 1 'Will Show The Report
  
  End With
  </code></pre>