Field in CSV export not behaving

hgus393

Registered User.
Local time
Today, 08:15
Joined
Jan 27, 2009
Messages
83
Hi all :)!

I'm exporting a csv file with transfer text macro (see below)

DoCmd.TransferText acExportDelim, "FinalQ Export ", "FinalQ", "C:\Temp\Final.csv"

It works like a charm, but I have field in this export that when I bring it up in notepad it shows 2 decimals. The field itself in the table is stored as double, no decimals. I have tried to format the field in the query that is exported to the following:
format([Field],#) - doesn't work when exported
cstr([Field]) - Doesn't work either

Does anyone know another way?:confused:
 
Last edited:
Have you tried CLng([Field])? That should remove decimal places. Even better would be to store the field as a Long integer if you will never need the decimal places.

Scott
 

Users who are viewing this thread

Back
Top Bottom