Subform date filter

Sharon Hague

Registered User.
Local time
Today, 23:09
Joined
Jul 10, 2003
Messages
138
Hi All

I have a date field called "MyDate" in a subform I have created.

I have created a label called Mth next to this field and in it's control source is =[MyDate] and set its format to m so that it dispalys the month.

When I try to filter records by month it doesn't work properly as it looks at the exact date rather that the month date.

How can I get this to work?
 
Set your field to integer and use Month(mydate)

Regards
 
Namliam

Morning!

Sorry to appear thick! but how do I change the field to Integer?

I have looked through the help but cna't find it.
 
what i meant is remove the format or maybe change it to integer (#0) or something alike...

Sorry for the confusion...

Regards
 
Bingo!

It has worked, however, I didn't realise at the time but my filter by selection icon has dissapeared.

Therfore I cannot filter the records anyway.

Why is this?
 
Probably because its a label?! Try using a text box instead...

Regards
 
Allow filter property set to yes?

Maybe you just cant "Filter by selection" on a calculated field?! not sure...

Sorry

Regards
 
Namliam

The strange thing is is that I have just created a query to see if it did the same but it doesn't - It lets you filter by selection. I can't understand why it won't do the same through a form.

However, I don't want to have to create a query each time I want to use this.
 
From this point (beeing so far away and all) i do not have a clue :( sorry...

Regards
 

Users who are viewing this thread

Back
Top Bottom