Excel VBA Error "Subquery returned more than 1 value"
Posted on 2010-08-29
So I have a query in Excel VBA code that's usign a subquery which is returning more than 1 row, so I get this:
"Subquery returned more than 1 value. This is not permitted when the subquery follows =, !=, <, <= , >, >= or when the subquery is used as an expression"
How do I go about handling this error? I'd like to have a form popup (which Ive already designed" which prompts the user for a name. I'd then run another query specifying that name.
How do I check to see if more than 1 row was returned, or how do I check for this error so I can have the other form display? Thanks!