Avatar of M A
M AFlag for United States of America asked on

filter report based on dates

I followed the below link to filter the report based on dates selected in the textbox
https://www.experts-exchange.com/Programming/Languages/SQL_Syntax/Q_28050231.html

It is not getting filtered it is showing the entire report. below is my code.

Textbox names
Shipment_Date_From
Shipment_Date_To
Field name in table is "Shipment_Date"

DoCmd.OpenReport "ShipmentReport_datewise", acViewPreview, "", "([Shipment_date]>=#" & Format(Forms!Reporting!Shipment_Date_From, "dd-mm-yyyy") & "#) And ([Shipment_date]<=#" & Format(Forms!Reporting!Shipment_Date_To, "dd-mmm-yyyy") & "# )"


Can anyone help to sort out this
Microsoft AccessVisual Basic.NETVB Script

Avatar of undefined
Last Comment
M A

8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
Guy Hengel [angelIII / a3]

Log in or sign up to see answer
Become an EE member today7-DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform
Sign up - Free for 7 days
or
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
See how we're fighting big data
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
ask a question
Guy Hengel [angelIII / a3]

the above presumes the field is date.
if it's text, with the format dd-mm-yyyy you cannot use >= and <= directly ...
SOLUTION
mbizup

Log in or sign up to see answer
Become an EE member today7-DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform
Sign up - Free for 7 days
or
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
See how we're fighting big data
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
ask a question
ASKER
M A

Thanks it worked with mm-dd-yyyy
 I appreciate if you can guide how to make it landscape.
As of now it is opening in portrait
SOLUTION
Log in to continue reading
Log In
Sign up - Free for 7 days
Get an unlimited membership to EE for less than $4 a week.
Unlimited question asking, solutions, articles and more.
ASKER
M A

Many thanks
Experts Exchange is like having an extremely knowledgeable team sitting and waiting for your call. Couldn't do my job half as well as I do without it!
James Murphy