This below code I am using to call report of prescription. I am using crystal report 8.0 & database is ACCESS 2000.
but my problem is that when I add one more record into database it unable to display that record. I mean it only shows the data which is saved with that report. I tried with removing tick from "saved data with report" option but that give another error that "cannot connect SQL Server".
In short my report is not "Refreshing" whenever I call that report so plz tell me is there any procedure to refresh that report at run time.


VB Code:
  1. frmreport.CRreport.Connect = DE.Connection1
  2.         frmreport.CRreport.ReportFileName = App.Path + "\rptprescription.rpt"
  3.         str = "{presciption.dateofvisit} = '" & DTPicker1.Value & "' and {presciption.pname} = '" & cmbpatientname.Text & "'"
  4.         frmreport.CRreport.Destination = crptToWindow
  5.         frmreport.CRreport.WindowParentHandle = frmreport.hWnd
  6.         frmreport.CRreport.SelectionFormula = str
  7.         Screen.MousePointer = Default
  8.         frmreport.CRreport.Action = 1