Export to excel

Joy83

Member
Local time
Today, 07:33
Joined
Jan 9, 2020
Messages
116
Hi
I am exporting a temporary table in access to excel. It transferred all the complete data.
However, the format has some issues

I am using the exported figures to create a detailed report that contains charts and some information all in excel

when I export the data to the excel sheet,
I get this green mark on each cell (attach example)
My code doesn’t work unless I double click on each cell.
I assume the format need to be fixed during the transfer or something.


This is the code I am using to export:
Domd. TransferSpreadsheet acExport, acSpreadsheetTypeExcel12,"TempTable","C: \Chart.xlsx”,true

is there anyway to export that data with general or number format without having this green flag
 

Attachments

  • 4E40C3AE-D9E3-4211-8F94-6C4C5EB8D07B.jpeg
    4E40C3AE-D9E3-4211-8F94-6C4C5EB8D07B.jpeg
    159.8 KB · Views: 236
in query design,
you can right click on the field (in the grid) and set the format for that cell.
It should now export with the correct format.
 
you bring your Temp table in design view and change those last 4 fields to Numeric.
 
you bring your Temp table in design view and change those last 4 fields to Numeric.
Thanks for your reply
I am exporting a table and I am specifying the type of field there already
 
Ok it is working now
It looks that my excel file was corrupted
I created a new one and it worked

Is there any way to delete a chart in a specific sheet
Without deleting the sheet itself
 
Dim i As Integer
Dim shp As Shape
For i = ActiveSheet.Shapes.Count To 1 Step -1
ActiveSheet.Shapes.Item(i).Delete
Next
 

Users who are viewing this thread

Back
Top Bottom