Gustav Brock
Gustav at cactus.dk
Thu Nov 30 11:08:52 CST 2006
Hi Keith I think you need to rethink this. Creating reports to export to Excel to export to csv .. doesn't make sense. If you can't extract and build the requested records with one query, use two or more and collect them in a union query - or write to a temp table - which you use as source for the export to csv (if this is the optimum format for the import). Writing a csv in VBA - without the built-in export tool which can cause some troubles - is piece of cake and has been described numerous times here. You can also use a query to write the text file directly with the help of the schema.ini file: http://databaseadvisors.com/mailman/htdig/accessd/2004-October/028800.html /gustav >>> Kwilliamson at RTKL.com 30-11-2006 16:08:07 >>> Man...I forgot what a pain in the A@& getting reports out of Access is. I asked earlier how to export a report into csv format....doesn't seem that is likely. I need to ultimately generate a csv format file, to import into our sql-based application. This is for journal entries. I have written a couple of reports to generate journal entries....utilizing the different levels of grouping and summing. A good bit of the report is taking data, at different groupings, and calculating percentages to apply to user-entered data (for allocating overhead to different entities and account numbers.) Since csv is out, I am resigned to bring the data into excel...and then export to csv format. The problem is that, oddly, when I am looking at the data on the report (on screen) and then hit the "Analyze It with Excel" button....the columns come over in different order than the report. Plus, one of the fields is a text field = "00". It keeps coming into Excel as = 0 (general format.) I can't think of a way to store the values, and export values and formulas to Excel...as Rocky suggested. Any help is greatly appreciated. Regards, Keith E. Williamson | Assist. Controller| kwilliamson at rtkl.com RTKL Associates Inc. | 901 South Bond Street | Baltimore, Maryland 21231-3305 410-537-6098 direct | 410-276-2136 fax | www.rtkl.com <http://www.rtkl.com/>