Something Different

lead 27

Registered User.
Local time
Yesterday, 16:48
Joined
Mar 24, 2007
Messages
147
Hi
So far you havent let me down so here goes . . .

I have a list of kit in a table and I would like to make a form so that i can just type in the sizes required and I will get a list of Serial Numbers that I can use

I am thinking along the lines of a query but having trouble visualising how I can go about it

Any ideas???
 
Well there are a number of ways you can do this.

Here is a possibility:

click a button to open a form linked to a table for your value specifications
Input your values and click a button in that form to submit the values, and close and then reopen the same form.
A sub form could then be linked to a query that relates the specifications in the valuetable to your other table(s) and shows your desired info?
Keeping it in one form (with an embedded subform) with a button to open and close the form allows you change the input values at will.

Is this too vague?
 
thanks for getting back to me. i think I understand what you mean.
I have made a query which is ok however I cant link it so that if I type a number in a txt box then click the query it will use the number in the txt box.

can you go into a bit more detail about your idea
 
Well, yes, but that would be more time consuming for both of us. I'd have to explain about Public functions and how to use that in a query.

Probably the easiest way would be to just create a seperate table for your input values and link the form to it.

Next, in your query, add that new table to the the query.
If the input values are expected to be exact matches, you can simplify it by linking the input value column to the column in the main table that contains the specifications you're trying to isolate.
If the input values are not exact matches, then do not link the two tables, but rather use the values in the critera section as a greater than, and/or less than, which ever is your preference.

Test that query by manually adding some values to the new table and then look at the query in datasheet view.

When you have it working the way you want, then open your form in design view, and add a sub-form linked to that query.

As support for the form, you'll need to add an extra query to clear the temp table when you're done or you could end up with more than one record in it, which would add unwanted results to the sub form.

The idea is that this new temp table only have one record in it.
If it need to have more than one column (e.g. a high side and a low side), that's cool.

Your form will need to have a button to requery if you change the values, and it will need another button to close the form and then perform whaat ever other functions you want with the record matches.
I don't know what else you've got going on before or after this process.
YOu can build this button functionality in Macro builder, and later, if you get to feeling extra motivated, you can convert the macro to VBA and start reading it to try and understand a bit more about VBA.

Is this getting close for you?
 
I know that this is alot to ask but is there anyway you could quickly make up an example and send it me (just the layout to give me an idea)?
 
OK, sorry for the delay, but I had to run an errand first.

Here is a sample database for you.
I'm not entirely sure of your usage, so it may not be directly applicable, but you should be able to get the idea from this.
I dressed up the criteria for the match query such that you do not necessarily have to have a value in all criteria fields to get a match for the provided value(s).

I have the main table populated with some sample records to match against.

If you click on the forms button, and double click Origin_Form, it should be self explanatory from there.

This assumes you will enter to a matching form from an origin form, but since I do not know what you want to do with the matched information, when you close and return, it clears the criteria table.
In theory, rather than closing and clearing the table, you could leave the tble populated and use the query results to populate an order table, etc.
Ultimately, when ever you're done with the matches, you will need to clear the criteria table so you start fresh the next time.
 

Attachments

Last edited:
thank you for your help that looks great I will see what i can do

Thank you
 

Users who are viewing this thread

Back
Top Bottom