Hi Gostap,
the OpenReport action has a very useful parameter that allows you to
specify a WHERE clause...
the generic syntax is
DoCmd.OpenReport ReportName, View, FilterName, WhereCondition,
WindowMode, OpenArgs
and, here are some examples:
~~~~~~~~~~
Dim mWhere as string
mWhere = "TestDate >=#12/19/06 22:30# " _
& " AND TestDate <#12/20/06 22:30#"
DoCmd.OpenReport "ReportName", acViewPreview, , mWhere
~~~~~~~~~~~
Dim mWhere as string
mWhere = "DateValue(TestDate)=#12/19/06#"
DoCmd.OpenReport "ReportName", acViewPreview, , mWhere
~~~~~~~~~~~
you can, of course, build the mWhere string instead of literally
specifying it...
If you are using another date format than American, look at this link:
International Dates in Access - Allen Browne
http://allenbrowne.com/ser-36.html
Warm Regards,
Crystal
*
(: have an awesome day :)
*
MVP Access
Remote Programming and Training
strive4peace2006 at yahoo.com
*
> Hi;
>
[quoted text clipped - 19 lines]
>
> Gostap
Gostap - 11 Jan 2007 10:27 GMT
Dear Chrystal
Thank you very much for kind reply!
best Regards
Gostap
>Hi Gostap,
>
[quoted text clipped - 43 lines]
>>
>> Gostap
strive4peace - 12 Jan 2007 10:13 GMT
you're welcome, Gostap ;) happy to help
Warm Regards,
Crystal
*
(: have an awesome day :)
*
MVP Access
Remote Programming and Training
strive4peace2006 at yahoo.com
*
> Dear Chrystal
>
[quoted text clipped - 50 lines]
>> [quoted text clipped - 19 lines]
>>> Gostap