Help with Subform (1 Viewer)

iain1978

Registered User.
Local time
Today, 12:04
Joined
Nov 26, 2004
Messages
30
Hi,

I've got a simple database with a form which, has a sub form. The main form has a field called Staff ID.

I want the sub form to be able to list all records with the same Staff ID as the one you are looking at. For example if the staff member had 5 records, when you looked at one them you could see the reference ID of all the others. Ideally I would like to be able to hyperlink these numbers so when selected it would open another form showing the details under that reference ID. That however is a nice to have and another problem. It would be appreciated if someone could let me know what I'm doing wrong with respect to my sub form.

I'd happily supply a copy if you need one but I cant attach one as it is too big apparently if you do want to see a copy please email me at imackay@blueyonder.co.uk

Thanks.
 

KenHigg

Registered User
Local time
Today, 07:04
Joined
Jun 9, 2004
Messages
13,327
Do you have your two tables set up with a one to many relationship?
 

iain1978

Registered User.
Local time
Today, 12:04
Joined
Nov 26, 2004
Messages
30
No I don't

I just have one table

What I want to happen is, while reviewing a record for a staff member the form also shows the reference ID (primary Key) of all other records that maybe raised against that particular person.

In essence what I want the form to do is,

If the Staff ID (in the form I'm Viewing) matches the staff ID of any another record in the datasheet. The form will display the reference ID of all those records on the current form.

I hope this is not to confusing.

I was under the impression that a sub form was the easiest thing to do but I'm open to offers if it is not??
 

KenHigg

Registered User
Local time
Today, 07:04
Joined
Jun 9, 2004
Messages
13,327
I suppose you could do this with a subform but I would probably use a combo box and then use it as a filter. Think this would work?
 

iain1978

Registered User.
Local time
Today, 12:04
Joined
Nov 26, 2004
Messages
30
Thanks for your help with this matter. I manged to sort it out with a list box and refresh comand.
 

Users who are viewing this thread

Top Bottom