NetNomad312
Technical User
Sorry, I know this is probably a newbie question, but my VB is rusty and I'm rather new to Access. I'm trying to create a form in Access 2003 that includes two main things: a list box and a subform. The list box contains a list of item names as entered in a certain table. What I want is to get the subform, in datasheet view, to display whichever records have the name that you double-click on the list. I read in MSDN that you can set this by using the filter property ("Me.filter = [whatever]"). So I tried accessing the subform's filter property from the list box's On Double-Click command. I was trying:
[On double-clicking the list box]
Subform.Form.Filer = [the list box's itemdata]
When I double click, I get an error saying I can't change this property. Then I tried applying a test filter on the subform's Form_Load, and that worked. But I apparantly can't access the subform's filter from the main form (or any control on it). So how do I pass this string to the subform?
[On double-clicking the list box]
Subform.Form.Filer = [the list box's itemdata]
When I double click, I get an error saying I can't change this property. Then I tried applying a test filter on the subform's Form_Load, and that worked. But I apparantly can't access the subform's filter from the main form (or any control on it). So how do I pass this string to the subform?