Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Report Field Calculation based on start date

Status
Not open for further replies.

Tarbuza

Technical User
Dec 13, 2000
56
US
I have following field in my report

Action
Start Data
End Date
Qty
2003 : Formula is Qty*5, if start date falls in 2003 then Qty*6
2004 : Formula is Qty*12, if start date falls in 2004 then Qty*13
2005 : Formulat is Qty*12, if start date falls in 2005 then Qty*13

I started something like this but I am stuck as I am new to Access VBA. Please help.

Private Sub Detail_Format(Cancel As Integer, FormatCount As Integer)
If Not IsNull(Me. START_DT) Then

Select Case Year(Me. START_DT)
Case 2002

Case 2004

Case 2005

Case 2006

End Select
End If
End Sub

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top