422,727 Members | 2,161 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 422,727 IT Pros & Developers. It's quick & easy.

Recordset.Filter

100+
P: 111
how do i use Recordset.Filter to reference the current form? i tried using

Expand|Select|Wrap|Line Numbers
  1.     Set rst = New ADODB.Recordset
  2.     rst.Open "tblPaxInfo", CurrentProject.Connection
  3.  
  4.     rst.Filter = "([GroupNumber]= me![GroupNumber]) AND ([ResNumber] = me![ResNumber])"
but i get an error "arguments are of the wrong type, out of acceptable range or in conflict". it doesn't like the me!'s, because if i put in an actual number - it works.
Nov 1 '07 #1
Share this Question
Share on Google+
1 Reply


100+
P: 111
nevermind - stupid syntax mistake!

fixed to:

Expand|Select|Wrap|Line Numbers
  1. rst.Filter = "[GroupNumber]= '" & Me![GroupNumber] & "' AND [ResNumber]= '" & Me![Individual Res #] & "'"
Nov 1 '07 #2

Post your reply

Sign in to post your reply or Sign up for a free account.