Create a calc caled c_report_date:
Date ( Month (invoice_date); 1; Year (invoice_date) )
Now you can just search in this field for the month and year combo that you want such as 5/1/2009.
Also keep in mind that you could manually search for a date range itself in the invoice_date field.
Enter Find Mode 
Set Field [invoice_date; "1/1/2009...12/31/2009"]
Perform Find 
I have created 1 calculation field called c_report_date and
put the Date ( Month (invoice_date); 1; Year (invoice_date) )
When I try searching by month (Mei or 5) and year (2009), it cannot
find the record. FYI, I want to search by month (Mei or 5) instead of
5/1/2009 as well as year.
Well if you just want to search by "5" then all your calc has to do is be Month (invoice_date) and search in there. But this will find all records in May, not just for this year.
Well, what I intend to do is try to use 2 fields for month and year for searching.
What I did like this:
But when i browse the layout, no data is displayed for these 2 fields.
I'm also cannot search by these 2 fields as no data is found.
Your advice much appriciated!
"Well, what I intend to do is try to use 2 fields for month and year for searching."
If you have a true date field, you can search for 5/2009 and get all records for May, 2009. You can script it as well. So you can provide your Users month and year global fields and then search portion of your script could be:
Enter Find Mode [ uncheck pause ]
Set Field [ yourDateField ; globalMonth & "/" & globalYear ]
Perform Find [ ]
Thanks LaRetta, it works! :manvery-happy: