Reffering to fields on a subform

S

Shaun Allan

I've got a music database with fields for Artist and
Title, amongst others. They appear on a subform
frmMusicDetails placed on the main form frmMusicRecords.
I've got the Artist combo box, using DISTINCT, to only
list each artist once (for example Westlife have 3 entries
on the database). My problem is getting the Title field
combo, once an artist has been selected, to only list the
albums by that artist, and not every album title I've
got. I can do this on a single main form with the Row
Source set to "Select tblMusic.Title where
tblMusic.Artist=forms!frmMusicDetails.Artist" (or
something like that), but when it's done on the subform,
it doesn't work.
 
M

Michel Walsh

Hi,

or something "like" that?... the exact syntax is important... Since you refer to a top level from (the main form, not a subform or a subsub form), try


"SELECT Title FROM tblMusic WHERE Artist=FORMS!frmMusicDetails!Artist"



Hoping it may help,
Vanderghast, Access MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Refering to fields on a subform 2
Combo-box in Sub-form 6
Form / Subform Help 4
Finding a Record 1
Subform - lookup data 1
subform - looking up data 3
ComboBox 4
Im a novice and need help with making a form 5

Top