Solved

Problem with naming a pdf file and setting criteria

Posted on 2011-09-23
7
192 Views
Last Modified: 2012-05-12
I am having trouble generating pdf file based on a criteria set in a query.  Currently the file name is as listed below;

Plan 92 Provider #1 07.08.2011

Plan 92 = is part of the that on the report (this is what I need to add based on that field in the table)
Provider #1 = Reference
07.08.2011 = DraftDate

I need to add the PlanType at the end of the file name based on the criteria set in the query.  This is where I am having trouble, the PlanType is in the “tluFundsImport” table.  I tried setting the criteria in the “qryRPT1” query to generated just those PlanType 92, but it is creating pdf for all files, and disregarding the query.  

I need to create a separate report for each Reference Number, and having a pdf file for each Reference, but only if there is a record:  an example of what I need is as follows:

Reference, PlanType, DraftDate, it should look like this: Provider #1 Plan 92 07.16.2011

I will be creating a different report for each Plan Type, and will need to generate just the records with these Plan Type for each Reference.

I file is attached.  Thanks in advance!

Test-EFT-08-24-11--5-New-2.accdb
0
Comment
Question by:Delores_C
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 2
7 Comments
 
LVL 120

Expert Comment

by:Rey Obrero (Capricorn1)
ID: 36589488
is the recordsource of your report the query "qryRPT1" ?

0
 
LVL 74

Accepted Solution

by:
Jeffrey Coachman earned 500 total points
ID: 36589782
Why is qryRPT1 a "Group By"  query...

In a general sense the recordset and the Report recordsource should be basically the same.

Also note that the pound symbol ("#") is a *restricted* character in Windows file names...
http://support.microsoft.com/kb/177506
0
 
LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 36589844
..and so is the period (".")
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 36589869
This "Kinda" works OK for me.
(it runs without errors, and produces 3 PDF files, all with *valid* file names)

If it is not what you wanted, then pleas state what is wrong with it.

Jeff
Test-EFT-08-24-11--5-New-2.accdb
0
 

Author Comment

by:Delores_C
ID: 36590159
Answer for Capricorn1:  Yes the qryRPT! isw the record source

Answer for boarg2000:  Problems:

1.  The file is still using the title, which is part of the script in the SQL, not the actual PlanType in the filename
There are 3 differenct PlanType in the table. I  should have deleted the Plan 92 from the script

0
 
LVL 74

Expert Comment

by:Jeffrey Coachman
ID: 36590429
So what are the *Exact* results you are looking for, based on the DB you posted?

In other words don't describe what is, or is not happening like you are doing above...

Literally list the *EXACT* results you are expecting.
Ex:
I need ____ files created
The first file should be named _____ and should have ____ records, ...etc
The second file should be named _____ and should have ____ records, ...etc
...etc
0
 

Author Closing Comment

by:Delores_C
ID: 36897305
The answer was part of the answer
0

Featured Post

U.S. Department of Agriculture and Acronis Access

With the new era of mobile computing, smartphones and tablets, wireless communications and cloud services, the USDA sought to take advantage of a mobilized workforce and the blurring lines between personal and corporate computing resources.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Access developers frequently have requirements to interact with Excel (import from or output to) in their applications.  You might be able to accomplish this with the TransferSpreadsheet and OutputTo methods, but in this series of articles I will di…
Ever visit a website where you spotted a really cool looking Font, yet couldn't figure out which font family it belonged to, or how to get a copy of it for your own use? This article explains the process of doing exactly that, as well as showing how…
In Microsoft Access, learn how to use Dlookup and other domain aggregate functions and one method of specifying a string value within a string. Specify the first argument, which is the expression to be returned: Specify the second argument, which …
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question