[AccessD] Query based on multiselect listbox

Stuart McLachlan stuart at lexacorp.com.pg
Wed Jun 4 16:41:44 CDT 2003


On 4 Jun 2003 at 16:21, Tim Thiessen wrote:

> Dear Group
> 
> I am trying to use a multselect listbox to serve as a the parameter for a
> query.  I'm using the IN operator but it doesn't seem to be working.  I'm
> using A97.  Here is the SQL
> 
> SELECT Invoice.RDC
> FROM Invoice
> WHERE (((Invoice.RDC) In ([Forms]![frmWrkShts]![RDCCriteria]))
> AND ((Invoice.[Invoice Date])<=[Forms]![frmWrkShts]![date]));
> 
> In the frmWrkShts, I have a text box (RDCCriteria) that is storing the items
> selected from the listbox.  That part is working fine.  However, when I run
> the query, 0 records are returned.  If I run the query with the items from
> the text box, I get the correct number of records.  Is it not possible to
> use the IN operator with a parameter query?
> 

It is possible.

What code are you using to populate your textbox?

-- 
Lexacorp Ltd
http://www.lexacorp.com.pg
Information Technology Consultancy, Software Development,System 
Support.





More information about the AccessD mailing list