473,326 Members | 2,090 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,326 software developers and data experts.

Report Trouble

I currently have a form "VIEW ALL ASSIGNMENTS" containing a subform
with record source "qryVIEWALLASSIGNMENTS. This query filters the
database based on two combo boxes on the form containing dates ([DATE1]
& [DATE2])

The idea is: "Please show me all assignments from [DATE1] through
[DATE2].

Here is my SQL Code for that:

SELECT ProjectInformation.EventType, ProjectInformation.ProjectName,
ProjectInformation.ProjectDescription,
ProjectInformation.ProjectStartDate, ProjectInformation.ProjectEndDate,
ProjectInformation.Status, ProjectInformation.ProjectOwner,
Sum(HoursWorked.HoursWorked) AS SumOfHoursWorked
FROM HoursWorked INNER JOIN ProjectInformation ON
HoursWorked.ProjectName = ProjectInformation.ProjectName
GROUP BY ProjectInformation.EventType, ProjectInformation.ProjectName,
ProjectInformation.ProjectDescription,
ProjectInformation.ProjectStartDate, ProjectInformation.ProjectEndDate,
ProjectInformation.Status, ProjectInformation.ProjectOwner
HAVING (((ProjectInformation.ProjectStartDate)>=[DATE1] And
(ProjectInformation.ProjectStartDate)<=[DATE2]))
ORDER BY ProjectInformation.ProjectStartDate,
ProjectInformation.Status, ProjectInformation.ProjectOwner;

The form and query work great! Now I am trying to create a "Printer
Friendly" report of the same information. However, when I try to
"Preview" the report, it creates a pop-up box asking for [DATE1] and
[DATE2]. For lack of words, it seems the report is not referencing
[DATE1] and [DATE2] in the query which is not referencing [DATE1] and
[DATE2] in the form.

Any suggestions would be greatly appreciated!

Feb 7 '06 #1
3 1323
Gox
dr******@gmail.com wrote:
I currently have a form "VIEW ALL ASSIGNMENTS" containing a subform
with record source "qryVIEWALLASSIGNMENTS. This query filters the
database based on two combo boxes on the form containing dates ([DATE1]
& [DATE2])

The idea is: "Please show me all assignments from [DATE1] through
[DATE2].

Here is my SQL Code for that:

SELECT ProjectInformation.EventType, ProjectInformation.ProjectName,
ProjectInformation.ProjectDescription,
ProjectInformation.ProjectStartDate, ProjectInformation.ProjectEndDate,
ProjectInformation.Status, ProjectInformation.ProjectOwner,
Sum(HoursWorked.HoursWorked) AS SumOfHoursWorked
FROM HoursWorked INNER JOIN ProjectInformation ON
HoursWorked.ProjectName = ProjectInformation.ProjectName
GROUP BY ProjectInformation.EventType, ProjectInformation.ProjectName,
ProjectInformation.ProjectDescription,
ProjectInformation.ProjectStartDate, ProjectInformation.ProjectEndDate,
ProjectInformation.Status, ProjectInformation.ProjectOwner
HAVING (((ProjectInformation.ProjectStartDate)>=[DATE1] And
(ProjectInformation.ProjectStartDate)<=[DATE2]))
ORDER BY ProjectInformation.ProjectStartDate,
ProjectInformation.Status, ProjectInformation.ProjectOwner;

The form and query work great! Now I am trying to create a "Printer
Friendly" report of the same information. However, when I try to
"Preview" the report, it creates a pop-up box asking for [DATE1] and
[DATE2]. For lack of words, it seems the report is not referencing
[DATE1] and [DATE2] in the query which is not referencing [DATE1] and
[DATE2] in the form.

Any suggestions would be greatly appreciated!


Instead [DATE1] use:
Forms![VIEW ALL ASSIGNMENTS]![DATE1]

and analogous:

Forms![VIEW ALL ASSIGNMENTS]![DATE2]

--
Gox
Feb 7 '06 #2
Which [DATE1] should be edited? In the Query?

Feb 7 '06 #3
Nevermind, I got that to work.

Here is something I would like to ADD. What if I want to further
filter by a ComboBox [CurrentUser]?

I tried the same logic, but will not work

Feb 7 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Gudni G. Sigurdsson | last post by:
Hi. I am working on a program for the .NET Framework written in C# with Visual Studio .NET. With this program, one can print a report realized with the Crystal Report software included with VS...
1
by: Nathan Bloomfield | last post by:
Does anyone know if there is any documentation which relates to Access2k + ? or can anyone help adjust the code? I am having trouble converting the DAO references. TITLE :INF: How to...
15
by: Mark C | last post by:
All, I have exhaustingly been looking through the newsgroups in search of a way to systemically output an Access 97 report to a pdf file using the full version of Adobe Acrobat. I want the user...
2
by: Keith Wilby | last post by:
A97 I have a report/sub-report setup and for some records in the main report, the sub-report is blank. I want to set the height of the sub-report to zero where it is blank. I've set all the "Can...
15
by: Richard Hollenbeck | last post by:
I tried to ask this question before on the 14th of January but I never got a reply. I'm still struggling with the problem. I'll try to rephrase the question: I have a crosstab query with rows...
3
by: chrisse_2 | last post by:
Hey, In my database i have images, linked to the database, corresponding to different records. I am having trouble making them show in the report. At the moment i can only get the one picture to...
5
by: David L. | last post by:
I'm running into a frustrating problem. ASP.NET 2.0 web application, against SQL'05, I'm trying to run a report against a 'table provider' (query) that excutes well within SQL MGT studio, and...
3
by: pv1 | last post by:
Hello, I am somewhat new to Access and vba, but am trying to complete a request that has been made of me. Access version 2002 WindowsXP. At this point these text boxes are bound to the table...
4
by: Henrootje | last post by:
I have a REPORT with in it a subFORM Now I have this label (lblMonth) that I want to change. How should I do this? What would be the proper event to do this? The lblMonth should contain the...
1
by: dontbe | last post by:
Hi Guys, I'm newbie in this forum,.. and i'm having trouble with Data Report. I've been read about How to Create Dynamic Report (thanks to Creative1). But now i have some other trouble (sorry...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...

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.