sir i want if user click on submit all the records should come form production table if it match dtpicker1 and dtpicker2 value i have
written a code but it is not working kindly let me know.
Private Sub Command1_Click()
Set rs = New adodb.Recordset
[B]rs.Open "select * from production where issue_date = dtpicker1.Value and dtpicker2.value, con, adOpenDynamic, adLockOptimistic[/B]"
If Not rs.EOF Then
With DataReport3.Sections("section1").Controls
.Item("text1").DataField = rs.Fields("productname").Name
End With
Set DataReport3.DataSource = rs
DataReport3.Orientation = rptOrientLandscape
DataReport3.Show
End If
End Sub