MS Access Query -> Excel

damsel

Registered User.
Local time
Today, 23:12
Joined
Jun 21, 2002
Messages
14
Hello everybody,

I have a query (thx very much to Colin :D) that contains parameters and everything.

So what I did I make a report out of this query and then I convert it to Excel. My problem is Excel cut the leading 0's on the conversion. So instead of having customer ID of 00121, it shows as 121 on Excel.

I have CustomerID as text on MS Access. So I guess Excel converts it to a number type instead of text.

Is there a way that I can maintain text to text ?

Thank you
 
There are a couple of ways to do this. If this is a one off where you are copying and pasting from Access to Excel, then the really quick way of getting round it is to pre-format your columns in Excel, ie, the column that is going to be your text field, highlight the whole thing, format to Text then paste in your data from Access.

If it's on a more regular basis, then you will need to put your table into a query, format your field as text and transfer across from that. There are quite a few posts on this subject if you do a search but have popped a couple here for you.

HTH

http://www.access-programmers.co.uk...adid=37268&highlight=format+text+export+excel

http://www.access-programmers.co.uk...adid=33763&highlight=format+text+export+excel
 
Thank you so much Ally
And sorry for asking question that's already been answered so many times before. Next time I'll be more careful.

Off I go trying the format function from Pat.

:)
 

Users who are viewing this thread

Back
Top Bottom