I write code in the button
Private Sub cmdshow_Click()
Dim str As String
str = "01/" & cmbMonth.ListIndex + 1 & "/" & MaskEdBox1.Text
dt = Format(str, "DD/MM/YYYY")
If isLoad = True Then
Unload dr1
Unload DataEnvironment1
Else
isLoad = True
End If
DataEnvironment1.cmdmonth (dt)
Unload Me
Load dr1
dr1.Show
in dataenvironment>command> I write code
Select * from main
Where Month(Date)=Month(dt)
And Year(Date)=Year(dt)
Order by Date Asc
and the I connect the database in dataenvironment manually.
Reputation Points: 14
Solved Threads: 78
Practically a Posting Shark
Offline 835 posts
since Jul 2008