Invalid Argument Error

  • Thread starter Thread starter Sam Nelson
  • Start date Start date
S

Sam Nelson

In Access 2000 - I am trying to run a select-query that
has a field that references a text field from a form that
is open. The field is as follows -

PaymentsDue: IIf(IsNull([Forms]![frm ContinueImport]!
[txtPaymentsDue]),"",[Forms]![frm ContinueImport]!
[txtPaymentsDue])

Most of the time, the query runs fine but occassionally if
the text string in the txtPaymentsDue text box is too long
(over 127 characters), the query will not run and instead
return an error stating "invalid Argument".

Any ideas on what causes this?
 
In Access 2000 - I am trying to run a select-query that
has a field that references a text field from a form that
is open. The field is as follows -

PaymentsDue: IIf(IsNull([Forms]![frm ContinueImport]!
[txtPaymentsDue]),"",[Forms]![frm ContinueImport]!
[txtPaymentsDue])

Most of the time, the query runs fine but occassionally if
the text string in the txtPaymentsDue text box is too long
(over 127 characters), the query will not run and instead
return an error stating "invalid Argument".

I'm not sure - but you might try

PaymentsDue: NZ([Forms]![frm ContinueImport]![txtPaymentsDue], "")

or, since a Null will display as a blank, just the form reference
itself.
 
No, the NZ function gives the same result. I've also
tried just the FORM REFERENCE itself as noted below, but
that also gives the same result.

-----Original Message-----
In Access 2000 - I am trying to run a select-query that
has a field that references a text field from a form that
is open. The field is as follows -

PaymentsDue: IIf(IsNull([Forms]![frm ContinueImport]!
[txtPaymentsDue]),"",[Forms]![frm ContinueImport]!
[txtPaymentsDue])

Most of the time, the query runs fine but occassionally if
the text string in the txtPaymentsDue text box is too long
(over 127 characters), the query will not run and instead
return an error stating "invalid Argument".

I'm not sure - but you might try

PaymentsDue: NZ([Forms]![frm ContinueImport]! [txtPaymentsDue], "")

or, since a Null will display as a blank, just the form reference
itself.


.
 
Back
Top