Where abouts are you getting your error?
If you hard-code the x as 1, does it return records?
If so then you aren't populating x properly.
for i = 1 to 10
x= sheets("Sheet1").cells(i,1)
Select.......id=x;
next i
However, if the hard-coded SQl isnt working then it's most likely a
connection problem.
And in that case.... you'll need to post more detail.
HTH,
Matt.
--
MattShoreson
------------------------------------------------------------------------
MattShoreson's Profile:
http://www.excelforum.com/member.php...fo&userid=3472
View this thread:
http://www.excelforum.com/showthread...hreadid=486866