views:

113

answers:

1

So there is a parameter box that open after a button click event runs an sql statement in vb for a list box to populate data. something like:

me.listbox.rowsource = "SELECT tblMain.ID, TblMain.FirstName, TblMain.LastName, tblMain.MobileNumber FROM tblMain;"

then i count the result for display like:

me.recordcounter = me.listbox.listcount

for some reason when I this button click event it still throws up a parameter box for the query asking for a mobile number?? which if you just click through gets you to the browse all results i am looking for. is there a way i can write something that automatically tells that box the ok has been clicked so it doesn't even appear? or is this avoiding something worse than a random pain??

thanks

EDIT:

apologies i just noticed that everything (all controls, etc) are in the form header?? too many people have access to this, its all mucked up. sorry...much fixes to do before I can even ask a legit question. acbSoundex from Cookbook is also in here and throwing this for a loop. thanks though

+3  A: 

The parameter box will appear if the query contains a field/param that is not in the table/not specified.

It would seem that the MobileNumber field (if what you state) might be spelled incorrectly, or is not part of the underlyinh table/query.

Verify that you table structure is correct in regards, to the query you supplied, or supply the table structure so that we can have a look.

astander