How can I pass Date-Range to crystal reports in vb.net

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • tasawer
    New Member
    • Aug 2009
    • 106

    How can I pass Date-Range to crystal reports in vb.net

    I have created Crystal Report to display data between two dates.
    From a vb Form, I need to pass the m_minDate and m_maxDate as the date range to Parameter 'MyDateRange'. I am struggling to know how to do this.

    I have tried to search on ParameterRnageV alues, but struggling to understand.


    For another report, I can pass single values with the code:
    Code:
    Dim rptViewer As New rptNamazTime
    
    rptViewer.DataSourceConnections.Clear()
    rptViewer.DataSourceConnections.Item(0).SetConnection("server", "dbname", False)
    
    ' Set Database Logon Details 
    rptViewer.SetDatabaseLogon("login", "password", "server", "dbname")
    rptViewer.SetParameterValue("SelectMonth", m_theMonth)
    crvNamazTime.ReportSource = rptViewer
Working...