Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / General 2 / January 2008

Tip: Looking for answers? Try searching our database.

Opening another form and loading data into it

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Ryan - 23 Jan 2008 14:51 GMT
I currently have sort of a search engine form. It has several options that
when selected creates a query on a large set of data. Everything seems to be
in order. Everything is based on my Generate button at the end. When I click
it, it is supposed to open a form with 2 graphs on it and a list. These
graphs and lists are supposed to be updated with the queries that the other
form has created. The probly I'm having is that since I'm opening a new form
it is not loading the query and updating the graphs. If I just put the graph
on the same page as the main form it updates no problem. It seems I do not
know how to make the button open up the new form, and at the same time update
the graphs with the query I just created. Any help would be much appreciated.
Pat Hartman - 23 Jan 2008 16:00 GMT
If you are creating the query as an SQL string, you can pass the string in
the Form's OpenArgs argument (there may be string length limitations to be
aware of) and in the Form's Open event, you can have code that takes the
OpenArgs argument and places the string in the form's RecordSource.

If Not IsNull(Me.OpenArgs) then
   Me.RecordSource = Me.OpenArgs
End If

There are other solutions that may be more appropriate depending on what you
are actually doing.

>I currently have sort of a search engine form. It has several options that
> when selected creates a query on a large set of data. Everything seems to
[quoted text clipped - 13 lines]
> the graphs with the query I just created. Any help would be much
> appreciated.
Ryan - 23 Jan 2008 16:12 GMT
each combo box is referenced in the SQL code of the query. I have little to
no knowledge of VBA. My query should filter the data based on the combo box's
values and then when I click the generate button, I want it to open up
another from where I am keeping my graphs and upload the query data into the
graphs. Everytime I fill in the combo box values, though, when I load the
document the graphs just load blank. I also have a button on the main form to
open up the query, but its not even updating that.

> If you are creating the query as an SQL string, you can pass the string in
> the Form's OpenArgs argument (there may be string length limitations to be
[quoted text clipped - 25 lines]
> > the graphs with the query I just created. Any help would be much
> > appreciated.
Pat Hartman - 23 Jan 2008 21:06 GMT
You may need to add requeries to the current event of the form's open event.

Me.graph1.Requery
Me.graph2.Requery
..

> each combo box is referenced in the SQL code of the query. I have little
> to
[quoted text clipped - 43 lines]
>> > the graphs with the query I just created. Any help would be much
>> > appreciated.
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.