>In the following code, data is dumped from query result to an Excel file,
>starting at cell a4. My problem is the data in the first column from my
[quoted text clipped - 7 lines]
> 'dump all data, starting at cell a4
> objXLws.range("a4").CopyFromRecordset rs
Try putting cstr(fieldname) around the appropriate fields in the
query. That might, or might now work.
Tony

Signature
Tony Toews, Microsoft Access MVP
Please respond only in the newsgroups so that others can
read the entire thread of messages.
Microsoft Access Links, Hints, Tips & Accounting Systems at
http://www.granite.ab.ca/accsmstr.htm
Tony's Microsoft Access Blog - http://msmvps.com/blogs/access/
Fractal - 30 Apr 2008 18:12 GMT
Using Cstr in the query actually removed the prefix 0's. I got "6" back in
the query result. Do you have other suggestions? Thanks.
> >In the following code, data is dumped from query result to an Excel file,
> >starting at cell a4. My problem is the data in the first column from my
[quoted text clipped - 12 lines]
>
> Tony