View Full Version : Creating a custom report?
I am trying to create a form or report that prompts me for the data I am trying to collect. So that when I open the report I have a filter in place for the report that asks me what I want to see, in this case size. Ex:
double click report / prompted for size / enter 2" / report prints all lines that are 2".
This isn't hard normally but it seems all exits have been blocked by Bentley. Anyone know how to make this work?
tw_echo
04-03-2006, 04:07 PM
I just gave it a try and here is what I figured out.
-Create a report, I just copied the packaged 'Line List - Process' report.
-Edit new report in Datamanger.
-Within Access, open the report's recordsource.
-In the criteria for the RUN SIZE: PSZ column enter the following - [Please enter size:] + chr(34)
Note: you need the chr(34) which represents the ". Access will not understand the criteria if you write 2"
-Still in query design mode, goto File --> Save As and call it whatever. Be sure to save everything and it should work like a charm
Tim...
Thanks for that Tim. I tried your method but I think I am misunderstanding something. I know that I can edit a view > design with access and set the criteria there. What I am looking to do is add some filter to the report that prompts me for whichever value I want to see. I am not sure if a report will prompt you or not is the thing. Here is the email from Bentley support:
Hey Dave –
You should be able to apply a filter to your report.
Open Access and do a search for Filter.
For information about how to apply a filter (filter: A set of criteria applied to data in order to display a subset of the data or to sort the data. In Access, you can use filtering techniques such as Filter By Selection and Filter By Form to filter data.) to display just the records you want in the form (form: An Access database object on which you place controls for taking actions or for entering, displaying, and editing data in fields.) or report (report: An Access database object that prints information that is formatted and organized according to your specifications. Examples of reports are sales summaries, phone lists, and mailing labels.), see the topic Filter: Limit the number of records in a view or report.
With the filtered records displayed, click the arrow next to the New Object button on the toolbar, and then click AutoForm or AutoReport.
The new object uses as its record source (record source: The underlying source of data for a form, report, or data access page. In an Access database, it could be a table, query, or SQL statement. In an Access project, it could be a table, view, SQL statement, or stored procedure.) the table or query in which the filter was created — the object inherits this filter. When you view a report, the filter is applied automatically each time you subsequently view that report. However, when you view a form, the filter is applied automatically only the first time after you have created it. The next time you open the form, you need to apply the filter yourself, and then each time after that.
If you subsequently change the filter in a table or query, the filter will not be reflected on the form or in the report — you will need to manually apply the latest filter to the form or report.
Ron Plaisance
Bentley Systems, Inc.
AutoPLANT Technical Support Group
--------------------------------------------------------------------------------
From: Dave Tyner
Sent: Monday, April 03, 2006 8:56 AM
To: Ron Plaisance
Subject: RE:
Hi Ron. If I cannot create a parameter query, can I create a parameter report? Do I have to do that in a form? Can I make a form from the .adp file?
Dave Tyner
Designer
I know how to apply a filter, just not one that prompts me. Also, I need this to happen in DM as I don't want engineers and other CAD guys to have to "back door" to make it work. I'm just looking for a way to avoid making extra views / reports for what I want to see. Thanks!
from bentley support:
Dave –
That is what you discovered and was reported as a bug.
It worked rather well in previous versions.
All you had to do was place a in the criteria field when in Design mode.
It no longer works. As reported on March 30th, I logged this as Tracker # 5403.
Ron Plaisance
Bentley Systems, Inc.
AutoPLANT Technical Support Group
tw_echo
04-04-2006, 01:13 PM
Dave,
Having a string posted in square brackets in the criteria of a query, will prompt you with the text that was entered in the criteria. In the example, that I showed you, you should have been prompted with a box that stated
"Please enter size:" adn then you could have entered a value that you would like. This in turn, creates a filtered recordsource. Try it with a query.......
In any case, the solution that I did propose to you...I just found out that it does not work on a consistent basis. It appears that Bentley datamanager database does not save my new query that I had the new report based on.....ARGHHH. I guess we are stuck till next version.
Tim...
Yep they have it blocked somehow. I found a great tutorial for making a pop up form BUT, again, no love. Oh well - I am waiting on supports reply to my "can I create a form in DM" though I am quite sure of the answer.
Powered by vBulletin® Version 4.1.7 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.