473,659 Members | 3,082 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Opening ms access report based on dates

1 New Member
Hello am trying opening a report from a form based on the current record selected which is a date but it cant display the specified DATE record it only diplays all dates please help me with this.....?

THIS FORMULAR WORK WITH OTHER RECODE'S BUT NOT DATES
WHERE CONDITION: ="DATE_PAID= " & [DATE_PAID]
OR
VISUAL BASIC: DoCmd.OpenRepor t "TUTION_R", acViewPreview, , , , "DATE_PAID = " & Me.DATE_PAID
Aug 8 '22 #1
3 8817
NeoPa
32,568 Recognized Expert Moderator MVP
Hi there.

Welcome to Bytes.com.

Let me start by advising that using capitals as you have is considered shouting on the web. You should understand that it's no less insulting or annoying in this context than it would be in real life - so please avoid it in future.

Otherwise, your issue is a very common one. Made worse by the fact that the approach you use generally works in America - but rarely elsewhere. As much of the coding work and examples posted comes from there, and many (Not all but many.) there don't realise the extra complications of portability across national boundaries, there are a lot of examples that won't work reliably outside of that great nation.

For details see Literal DateTimes and Their Delimiters (#). It should tell you everything you need to know on the subject.
Aug 8 '22 #2
DJRhino1175
221 New Member
I do something similar, but not with dates. Here is the code I use and should get you what you want.

Expand|Select|Wrap|Line Numbers
  1. [Field]=[Forms]![Form Name]![Field]
Aug 9 '22 #3
NeoPa
32,568 Recognized Expert Moderator MVP
No DJ!

That is absolutely not the right way to handle dates within a SQL string. It works in America - but pretty much nowhere else. Did you even read what I wrote before posting that unhelpful addition to the subject? Date literals should always be strings that are formatted specifically for SQL. The use of default formats is incompetent and lazy, and only for those who haven't yet been told how to do it properly. No-one here any longer has that excuse.
Aug 9 '22 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

8
10759
by: lauren quantrell | last post by:
When I open an Access form I can have no recordset specified, then in the form's OnOpen event I can do something like: Me.paramaters = "@SomeColumn = 22)" Me.recordsource = "dbo.sproc123" But I can't do this in a report as it will prompt me for the parameters, even though they seem to be defined ahead of the recordsource. I have worked around this by opening reports to a bogus recordsource
9
5731
by: RMC | last post by:
Hello, I'm looking for a way to parse/format a memo field within a report. The Access 2000 database (application) has an equipment table that holds a memo field. Within the report, the memo field is printed within the detailed area. The problem is, the apllication is not setup properly, thus the users are entering data within the memo field as: location1 1/1/2005 1/1/2006
1
1488
by: A49553 | last post by:
I am trying to e-mail reports from Access that are based on pass-through queries going to an Oracle database. I am using Access 2003 on a Windows XP OS. I was able to e-mail these on my previous PC which used Windows 2000. I can e-mail reports from the same database that point to queries that reference local tables (not linked Oracle tables and not pass-through queries). I am e-mailing either by using File, Send To or by using the Send...
32
2670
by: wexx | last post by:
I have been looking for some time now (reading books off Safari, searching through forums,etc) I have found no solution to this problem. I turn to anyone of you that may be able to help me. I'm trying to create a database for work, using Microsoft Access 2003 on Windows XP. I have a product licensing database and it has one table named serial numbers, that table holds all the information associated with SNs, including customer name,...
0
2025
by: ChadK | last post by:
I am trying to open a report based on what the user selects on a form. Each individual criteria works but when I try to combine to pass multiple criteria it doesn't. I have read what I can find on here and tried different suggestions but nothing works. Can somebody take a look at my code and see what I'm doing wrong? strDocName = "ColdCallTotalsbyBDM" strLinkCriteria1 = " = Forms!!" strLinkCriteria2 = " >= Forms!!" strLinkCriteria3 = "...
2
2585
by: ccwells | last post by:
Hi, I am a novice to VB, using Access 2003 on a XP-SP2 platform, and I have a small database for tracking expenses, and want to be able to filter my expense report by date. I currently have a form with two list boxes, purchase and payment type, and then two date fields txtStartDate and txtEndDate. Filter works fine when no dates are chosen, problem is with my date picker - if I choose dates I get a "syntax error (missing operator)" error in...
13
3230
by: masteraccess2008 | last post by:
I create in Access report based on user defined function(UDF) in SQL Server which returns table. CREATE FUNCTION MyFunc_VP (@VP varchar(12)) RETURNS TABLE AS RETURN (SELECT...... In Access, I am calling a report with DoCmd.OpenReport method. DOCMD.OpenReport stDocName, acPreview
4
1519
by: jimmcg | last post by:
how can i limit the records seen in an access report based on a subtotal amount?
2
3477
by: fredmart | last post by:
Hi, I'm having problems finding a way to apply conditional formatting based on comparing the text contents of two fields in two different tables. What I'd like to do: I've got two tables that are identically structured with about 50 fields each. The two tables are used for two data inputters to independently enter the same data from the same source as part of a validation check. I want to be able to check which if any fields are...
0
7167
by: theaidencarl | last post by:
Hi everyone, I am currently working on an MS ACCESS database for one of our departments. I am currently stuck, wondering how I can make it less tedious and won't make the application crash due to heavy data in it. The reason why I had to do it on ACCESS is because right now, there are three different EXCEL worksheets that 2 different groups of people work on, just to be combined into one main report by the group leader. So I figured having it...
0
8851
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8747
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8528
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
1
6179
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5649
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4335
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2752
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1976
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1737
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.