title: Crystal report filter by daily, weekly and month in vb.net, ms access as the database
body: <p>it will be my first time asking here so I hope you will be easy on me ^_^</p>
  <p>I am making a program where I can generate report by daily, monthly and weekly using crystal report in vb.net. My daily reports are all set but I was confused on how to do it in weekly and monthly. I am using 2 datetimepicker, one for the 1st day of the month and the other is for the last day.</p>
  <pre><code>    Dim da As New OleDbDataAdapter(&quot;SELECT * FROM TITO WHERE [_DATE] between'&quot; + DateTimePicker1.Text + &quot; AND &quot; + DateTimePicker2.Text + &quot;'&quot;, con)
      Dim ds As New DataTable
      da.Fill(ds)
  
      CrystalReportViewer1.SelectionFormula = &quot;{TITO._DATE} IN DateValue (&quot; &amp; DateTimePicker1.Value.ToString(&quot;MM/dd/yyyy&quot;) &amp; &quot; ) TO DateValue (&quot; &amp; DateTimePicker2.Value.ToString(&quot;MM/dd/yyyy&quot;) &amp; &quot; )&quot;
  
      CrystalReportViewer1.RefreshReport()
      con.Close()
  </code></pre>
  <p><a href="https://i.stack.imgur.com/zKitT.png" rel="nofollow noreferrer">enter image description here</a>
  here is my code for reference. I getting errors like
  <a href="https://i.stack.imgur.com/8g9vz.png" rel="nofollow noreferrer">enter image description here</a></p>
  <p>please help,</p>