Link data from form to form? (1 Viewer)

Rick Stanich

King and Supreme Ruler
Local time
Yesterday, 19:21
Joined
May 13, 2009
Messages
93
I am trying to help some one with a DB but I have limited experience in Access VBA or DB's, I had thought it was a VBA problem. Thats what I get for thinking. ;)
Here is the dilemma.
the user opens a form (DAHM-A TOOLS DATA), selects "SEARCH", this opens another dialog where you can enter a numeric value. The problem we are having is tying that entered value to open another form (TOOL DESCRIPTION AND INFO) in the field "TOOLS". See attached image and DB.

Any help, hints, tips or examples are welcome.
 

Attachments

  • DAHM-A 1.jpg
    DAHM-A 1.jpg
    91.4 KB · Views: 80
  • DAHM-A.mdb
    964 KB · Views: 84
Last edited:

rainman89

I cant find the any key..
Local time
Yesterday, 22:21
Joined
Feb 12, 2007
Messages
3,015
Base your "Tools Description and info" form off of your "Tools Description and info query" instead of the actual table and then put

forms!search.text0 in the query criteria for the ID

Create a button to open the "Tools Description and info" form and you are done
 

Rick Stanich

King and Supreme Ruler
Local time
Yesterday, 19:21
Joined
May 13, 2009
Messages
93
As much as I hate to admit, I am not understanding how to change this:
"Base your "Tools Description and info" form off of your "Tools Description and info query" instead of the actual table".

I have my book (New Perspectives: Microsoft Access 2002), Im reading all kinds of stuff, but Im not getting something.
 
Last edited:

clincan

New member
Local time
Today, 03:21
Joined
Nov 23, 2009
Messages
3
I am trying to help some one with a DB but I have limited experience in Access VBA or DB's, I had thought it was a VBA problem. Thats what I get for thinking. ;)

Try the attached. This is a very quick thing.

I changed to record source in teh tools form to the query rather than the table.

I then added a combobox to the search window and populated it with the tools using the query wizard menu.

I then added code to open the tools form based on the selected contents of the combobox. (Note that I have left your original textbox on the form. And I have not adjusted column widths on the combobox.)

Study the code the search form to make sense. Note I have done this quickly and not put in any error trapping. Also I limited the combobox to only the results of the query -no editing allowed.

A few things. Do not name forms with spaces. You will come to regret this.

Your search window needs some explanation for the user.

Not clear about the fields ID and TOOL which seem to be identical.

Personally I hate macros. Use VBA directly instead.
 

Attachments

  • DAHM-A.mdb
    1.1 MB · Views: 87

clincan

New member
Local time
Today, 03:21
Joined
Nov 23, 2009
Messages
3
PS. I was exactly where you are now four years ago.

It does make sense eventually!!!!! And Google is your friend.
 

Users who are viewing this thread

Top Bottom