advice sought with queries

bone head

Registered User.
Local time
Today, 22:26
Joined
Feb 11, 2002
Messages
73
Ok this is probably simple. I have a database with a field for several locations “ factory” I need to produce an identical report for each factory.

I have started by doing a query for each factory and then producing a report.

This seems cumbersome to me and I am sure there must be an easier way, i.e. enter the Factory location and produce the report somehow.

The way I am doing it will work however it means I have to create a different report for each factory even though identical as well as having a button for each factory to activate the report.

I am probably missing something very obvious, any advice most gratefully received.

Cheers
 
In your query under the factory field enter this criteria

[forms]![yourfrmname]![yourcomboboxname] then base your report on the query this will then look to the value chosen in your form and display the selected details in your report.

If your still stuck I have posted samples of this on the forum. If you can't find them send me an email and I'll help you out.

Hay
 
Wow

That brilliant many thanks saved me loads of work and duplication

Bone head
 
Right Dumb question No 2

trying to make it more user freindly at the moment when i open query box comes up with the form name and feild names,

Can i change this to read enter Factory location required , been looking around but cant find wher this message box details appear.

thanks again

Paul
 
Hi Paul
Create your own pop up form if you haven't done so already and you can have any message you want. If you need help with this I can send you a demo.
hayley.baxter@bskyb.com and tell me which version of access you are using.

Hay
 
My you are quick

Many thanks will spend a bit of time llooking up pop up boxes

will reply if i get stuck again

Cheers

bonehead
 
Hayley

just fiddled with my queery some more and if i just put in the following [ enter factory location] in the factory field it works fine and shows that on th emessage box,

in doing so I have removed the code you sent

THis does sound far to simple though can you let me know if i am in danger of messing something up

Cheers
bone head
 
That should be ok it just means you'll need to type in the factory location then your report will find the matches. The way I gave you was looking to a combo box on a form for an entry chosen in your drop down list
 
Now i am bamboozled.

Obviously that would be much better with the drop down list, but when i put your code in, i was not getting a drop down list, i still had to enter the name of the factory.

i put the name of the feild as the name of the combo box where you said " your combo box" was this maybe incorrect

I would have thought that i would have given the combo box the same name as the feild, however it is possible that i changed the name of the feild slightly i do not recall.

is there a way to find the name of the relevant combo box as i know I would have given it a name

it may be this which caused my problems

Many thanks
 
You can find out the name of the combobox by going into the properties of the combo box. You are welcome to send me the form and query and I'll see what I can get working for you??

Let me know
Hay
 

Users who are viewing this thread

Back
Top Bottom