473,465 Members | 1,379 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

View Reports from from listbox or dropdown

DD
Hi
I want the user to be able to view all reports from a form either by
way of a list box or dropdown or ??
any help please

DD
Nov 12 '05 #1
7 2927
DFS
Your list or dropdown rowsource:

SELECT [Name] FROM MSysObjects WHERE [Type] = -32764 ORDER BY [Name];
"DD" <da**********@bigpond.com.au> wrote in message
news:14**************************@posting.google.c om...
Hi
I want the user to be able to view all reports from a form either by
way of a list box or dropdown or ??
any help please

DD

Nov 12 '05 #2
View Reports from from listbox or dropdown
Ok, the user creates a new rpt from the wizard,the backend is hidden.
Now i want the new rpt "whatever name to populate in the list box,,or
give access to the user to all the rpts and they choose their new rpt.
All this is done via a form

big job or what?
DD
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 12 '05 #3
Little job: you pick up the name of the report from the combo or list box in
its AfterUpdate event and use it in a DoCmd.OpenReport. That is, unless you
have reports, as is often the case, where the user enters values to limit
the number of records in the report -- those are probably going to require
that you create a separate form for each and open that form, so the user can
enter the limiting values, and then you execute a DoCmd.OpenReport from that
form.

Larry Linson
Microsoft Access MVP

"David Deacon" <da**********@bigpond.com.au> wrote in message
news:3f***********************@news.frii.net...
View Reports from from listbox or dropdown
Ok, the user creates a new rpt from the wizard,the backend is hidden.
Now i want the new rpt "whatever name to populate in the list box,,or
give access to the user to all the rpts and they choose their new rpt.
All this is done via a form

big job or what?
DD
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!

Nov 12 '05 #4
DFS
"David Deacon" <da**********@bigpond.com.au> wrote in message
news:3f***********************@news.frii.net...
View Reports from from listbox or dropdown
Ok, the user creates a new rpt from the wizard,the backend is hidden.
Now i want the new rpt "whatever name to populate in the list box,,or
give access to the user to all the rpts and they choose their new rpt.
All this is done via a form
If they can use the Report Wizard, the database window is open, right? So
they
already have Access to all the reports and there's no need for a form.

big job or what?
DD
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!



Nov 12 '05 #5
bo*****@localhost.not (Larry Linson) wrote in
<qx***************@nwrddc02.gnilink.net>:
Little job: you pick up the name of the report from the combo or
list box in its AfterUpdate event and use it in a
DoCmd.OpenReport. That is, unless you have reports, as is often
the case, where the user enters values to limit the number of
records in the report -- those are probably going to require that
you create a separate form for each and open that form, so the
user can enter the limiting values, and then you execute a
DoCmd.OpenReport from that form.


There's hardly ever a case where you should need to do that.

The best way to collect filter information from a form for a report
is to open that form as a dialog in the form's OnOpen event and
change the recordsource. This makes it possible to have a single
dialog form that is used for multiple reports. It also means the
dialog form doesn't have to know anything about any of the reports
it is used for.

--
David W. Fenton http://www.bway.net/~dfenton
dfenton at bway dot net http://www.bway.net/~dfassoc
Nov 12 '05 #6
"David W. Fenton" wrote
That is, unless you have reports, as is often
the case, where the user enters values to limit
the number of records in the report -- those
are probably going to require that you create
a separate form for each and open that form,
so the user can enter the limiting values, and
then you execute a DoCmd.OpenReport
from that form.


There's hardly ever a case where you should
need to do that.

The best way to collect filter information from
a form for a report is to open that form as a
dialog in the form's OnOpen event and
change the recordsource. This makes it possible
to have a single dialog form that is used for
multiple reports. It also means the dialog form
doesn't have to know anything about any
of the reports it is used for.


That's a good approach and it'll work if you have a number of reports all
limited by the same data... for example, dates. If you have other "selection
factors", you will either need other dialog forms, or you'll need to pass
information to the form to be displayed in lieu of labels. And, in most
applications I've worked on, there were a limited number of reports with the
same limiting/filtering data -- a few using a date range, others using a
geographic filter, some using a corporate structure selection, etc.. So,
while you could not conveniently get by with one "selection form", you could
get by with a few of them.

I suppose you could get by with one, if you did a good deal of code to
communicate between the Report and the Form, to display the proper number of
text boxes, or combo boxes, and the correct labels, etc., as well as to
retrieve the appropriate data and build the record source. But, generally, I
find it easier to maintain more forms and less complex code.

I worked on one system that had a "standard" selection form, but in an
attempt to simplify, they had put so much on that form that the code to
massage it for a given report was complex. And, too, not all the possible
entries were applicable for all the reports. The designers should have put
more thought, and more forms, into the process and it would have cut way
back on the processing and VBA code, and _maintenance_ time and effort
required. The information was picked up, validated, and processed in the
Open event of the Reports, BTW.

Larry Linson
Microsoft Access MVP
Nov 12 '05 #7
bo*****@localhost.not (Larry Linson) wrote in
<1t***************@nwrddc01.gnilink.net>:
"David W. Fenton" wrote
That is, unless you have reports, as is often
the case, where the user enters values to limit
the number of records in the report -- those
are probably going to require that you create
a separate form for each and open that form,
so the user can enter the limiting values, and
then you execute a DoCmd.OpenReport
from that form.
There's hardly ever a case where you should
need to do that.

The best way to collect filter information from
a form for a report is to open that form as a
dialog in the form's OnOpen event and
change the recordsource. This makes it possible
to have a single dialog form that is used for
multiple reports. It also means the dialog form
doesn't have to know anything about any
of the reports it is used for.


That's a good approach and it'll work if you have a number of
reports all limited by the same data... for example, dates. If you
have other "selection factors", you will either need other dialog
forms, or you'll need to pass information to the form to be
displayed in lieu of labels. And, in most applications I've worked
on, there were a limited number of reports with the same
limiting/filtering data -- a few using a date range, others using
a geographic filter, some using a corporate structure selection,
etc.. So, while you could not conveniently get by with one
"selection form", you could get by with a few of them.


Well, re-usability is only a secondary benefit of my suggestion.
The main benefit is making the opening of the report a unified
event, that you don't have to know "Oh, gee, I have to open that
report with this *form* instead of just opening the report."
I suppose you could get by with one, if you did a good deal of
code to communicate between the Report and the Form, to display
the proper number of text boxes, or combo boxes, and the correct
labels, etc., as well as to retrieve the appropriate data and
build the record source. But, generally, I find it easier to
maintain more forms and less complex code.
I have plenty of applications where these dialog forms get
repeatedly re-used. I have never used "adaptable" dialogs that
would enable/disable or show/hide particular criteria depending on
the report, because then you're breaking the implicit rule behind
the benefit of re-use, that the form needs to know nothing about
the report it is being used with.

If I *were* going to re-use a dialog and dynamically reformat it,
I'd definitely wrap the whole thing in a class module and use it as
the storage system for the data collected.
I worked on one system that had a "standard" selection form, but
in an attempt to simplify, they had put so much on that form that
the code to massage it for a given report was complex. And, too,
not all the possible entries were applicable for all the reports.
The designers should have put more thought, and more forms, into
the process and it would have cut way back on the processing and
VBA code, and _maintenance_ time and effort required. The
information was picked up, validated, and processed in the Open
event of the Reports, BTW.


I generally think it's worth it to code the dialog into the OnOpen
event (though you might want to have a bypass if the report's
filter is not zero-length, which would mean that it's being opened
with a WHERE clause) even if the dialog is used only once, simply
because it makes the dialog a "child" object of the report, rather
than the other way around. It also leaves open the possibility of
re-using the dialog, something that is much harder the other way
around.

--
David W. Fenton http://www.bway.net/~dfenton
dfenton at bway dot net http://www.bway.net/~dfassoc
Nov 12 '05 #8

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

Similar topics

2
by: David Deacon | last post by:
View Reports from from listbox or dropdown Ok, the user creates a new rpt from the wizard,the backend is hidden. Now i want the new rpt "whatever name" to populate in the list box,,or give access...
2
by: David Deacon | last post by:
OK I have not explained myself properly. 1. i have created a form with a btn the user clicks the btn and opens the default Microsoft LabelWizard the tbl the user draws the information from is...
7
by: tom | last post by:
Hi, I want a listbox below a hidden calendar control. The problem is that the listbox will shadow the calendar when the calendar is visible. How can I bring the calendar from back to front? ...
5
by: Kay | last post by:
Hello, I have two list boxes on my form, one initially displays with items and the other displays blank, by clicking a button, it is possible to move items from one box to another and vice a...
1
by: JIM.H. | last post by:
Hello, I have a data view linked to a table and a dropdown list for “LastName”. Now once I select something from dropdown list I want the data view refresh itself for selected LastName. I do...
1
by: acord | last post by:
Hi, I am having problem to get a value of the selected item from a dropdown listbox. Here is the JS function; function getSelectedItem(objSelect) { alert("in getSelectedItem"); alert...
3
by: Renilkumar | last post by:
Hi, I am using .net 2.0. I have a .aspx page with vb.net as codebehind. My form has one dropdown, 2 listboxes with add & remove button. During pageload I am loading all the values from the db to...
7
by: google | last post by:
I am trying to automate the way reports are printed in an Access 2003 database - I have ~200 records (people) who require between 5 and 10 customized reports (depending on values within certain...
11
tuxalot
by: tuxalot | last post by:
I have reports visible in a listbox on a tabbed form. The Row Source for the listbox is: SELECT .ReportID, .ReportName, .ReportCaption, .ReportCriteriaFlags FROM ORDER BY .ReportCaption; ...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
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,...
0
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...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development projectplanning, coding, testing,...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
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 ...

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.