Hi guys
I have a form called "Open balance sheet" that when it opens puts start and end dates into unbound text boxes.
the code i have on the forms on load event is this
Me.End_Date_Txt_Box = DateSerial(Year(Date), 12, 31)
Me.Last_Year_Start_Date = DateAdd("yyyy", -1, Me.Start_Date_Txt_Box)
Me.Last_Year_End_Date = DateAdd("yyyy", -1, Me.End_Date_Txt_Box)
Me.before_last_start_date = DateAdd("yyyy", -2, Me.Start_Date_Txt_Box)
Me.before_last_end_date = DateAdd("yyyy", -2, Me.End_Date_Txt_Box)
Me.last_date = DateAdd("yyyy", -3, Me.Start_Date_Txt_Box)
when the search button is clicked it opens up a form called "balance sheet" this form sums all the orders and stock in the system between the dates on the open balance sheet form
This works really well
what i can't get my head around is this
what is the code to put onto the balance sheet form that sums all the orders from dates less than equal to the date in the me.last_date text box on the "open balance sheet" form?
any help would be most welcome.
Steve