Help With Dates

dsomers

Registered User.
Local time
Today, 14:47
Joined
Nov 13, 2003
Messages
131
Hello all! I'm trying to use a statement from one of the Access books I have on finding dates within a certain range. Here is the statement I'm using though I modified it from the original from the book to try to fit my needs:

[Date Rend Paid] Between #m/1/yyyy# And #m/5/yyyy#

Obviously this is the incorrect syntax. But I want this statement to be able to hold true for every month of the year, automatically updating with each month.

How can I change this statement to do that?

Thanks!
David Somers
 
dsomers said:
I want this statement to be able to hold true for every month of the year, automatically updating with each month.

[Date Rend Paid] Between DateSerial(Year(Date()), Month(Date()), 1) And DateSerial(Year(Date()), Month(Date()), 5)
 
Thanks! But now I have a little different problem. The record I'm using has a monthly rent of $350, late fee of $17.50 if not paid between the 1st and 5th of each month, a previous balance of 0, and date rent paid as 11/16/2003. When I enter an amount lower than $350 (say $330), the balance is $37.50 which is correct. When I enter $350, the balance goes to 0 when the actual balance is $17.50 incurred because of the late fee. Here's the expression I'm using:

Balance: IIf(((([MonthlyRent]+[Prev Balance])-[Rent Paid])>0) Or ([Date Rent Paid] Between DateSerial(Year(Date()),Month(Date()),1) And DateSerial(Year(Date()),Month(Date()),5)),([Prev Balance]+[MonthlyRent]+[Late Fee])-[Rent Paid],([Prev Balance]+[MonthlyRent])-[Rent Paid])

I guess I've looked at this so much I can't tell where my problem is. Can anybody help me?

Thanks!
David Somers
 
I know the feeling

This seems about right:

Balance: IIf(((([MonthlyRent]+[Prev Balance]-[Rent Paid])>0) Or ([Date Rent Paid] Not Between DateSerial(Year(Date()),Month(Date()),1) And DateSerial(Year(Date()),Month(Date()),5))),([Prev Balance]+[MonthlyRent]+[Late Fee]-[Rent Paid]),([Prev Balance]+[MonthlyRent]-[Rent Paid])).

HTH
 
How do you change this to not charge them a late fee if they move in after the 5th of the month?

Thanks!
David Somers
 
Pleas stick to one post on the subject, you need to add the StartOfTenancy date into the equation
 
And how is that done? What would the actual expression look like?

Thanks!
David Somers
 

Users who are viewing this thread

Back
Top Bottom