Testado e a funfar:
'Inicia a variavel com o nome da planilha
vNome = "teste.xlsx"
Set db = CurrentDb()
Set cs = db.OpenRecordset("select * from Teste1;")
'Verifica se o arquivo não está vazio
If Not cs.EOF Then
'Concatena o caminho do arquivo escolhido pelo usuario com o nome da planilha criada
'verifica se o arquivo existe, se existir será excluido para criar um novo
If Dir(X & vNome) <> "" Then
Kill X & vNome
End If
'Transfere como planilha para o Excel
DoCmd.TransferSpreadsheet acExport, 10, "Teste1", X & vNome, True, ""
DoCmd.TransferSpreadsheet acExport, 10, "Teste2", X & vNome, True, ""
Set Excel = CreateObject("Excel.Application")
Set ExcelWBK = Excel.workbooks.Open(X & vNome)
DoCmd.SetWarnings False
Excel.Sheets("Teste1").Select
Excel.Application.DisplayAlerts = False
Excel.Application.Visible = True
'Zoom da página
Excel.ActiveWindow.Zoom = 80
'Cria a primeira linha em branco
Excel.Rows("1:1").Select
Excel.Range("A1:AK1").Select
Excel.Selection.Insert Shift:=-4121
Set ExcelWS = ExcelWBK.worksheets
Excel.Cells(1, 1) = "Dados"
Excel.Cells(1, 12) = "Produce"
Excel.Cells(1, 25) = "Memo"
Excel.Range("A1:Y1").Select
With Excel.Selection
.Font.Name = "Calibri"
.Font.Bold = True
.Font.Size = 11
'.HorizontalAlignment = xlCenterAcrossSelection
End With
Excel.Cells.Select
Excel.Cells.EntireColumn.AutoFit
Excel.Range("A1:K2").Select
With Excel.Selection.Interior
.ColorIndex = 15
End With
Excel.Range("L1:W2").Select
With Excel.Selection.Interior
.ColorIndex = 6
End With
Excel.Range("X1:X2").Select
With Excel.Selection.Interior
.ColorIndex = 2
End With
Excel.Range("Y1:AK2").Select
With Excel.Selection.Interior
.ColorIndex = 43
End With
With Excel.Selection.Borders(xlEdgeTop)
.Weight = "$00000004"
.LineStyle = -4119
.ColorIndex = -4105
End With
With Excel.Selection.Borders(xlEdgeLeft)
.Weight = "$00000004"
.LineStyle = -4119
.ColorIndex = -4105
End With
With Excel.Selection.Borders(xlEdgeRight)
.Weight = "$00000004"
.LineStyle = -4119
.ColorIndex = -4105
End With
With Excel.Selection.Borders(xlEdgeBottom)
.Weight = "$00000004"
.LineStyle = -4119
.ColorIndex = -4105
End With
Excel.Range("A2:AK2").Select
Excel.Selection.Font.Size = 11
Excel.Selection.HorizontalAlignment = xlCenter
Excel.Range("A1:A1").Select
Excel.Columns("l:w").Select
Excel.Selection.NumberFormat = "#,##0.00;[Red](#,##0.00)"
Excel.Columns("y:ak").Select
Excel.Selection.NumberFormat = "#,##0.00;[Red](#,##0.00)"
Excel.Sheets("Teste2").Select
'Zoom da página
Excel.ActiveWindow.Zoom = 80
'Cria a primeira linha em branco
Excel.Rows("1:1").Select
Excel.Range("A1:AK1").Select
Excel.Selection.Insert Shift:=-4121
Set ExcelWS = ExcelWBK.worksheets
Excel.Cells(1, 1) = "Dados"
Excel.Cells(1, 12) = "Produce"
Excel.Cells(1, 25) = "Memo"
Excel.Range("A1:Y1").Select
With Excel.Selection
.Font.Name = "Calibri"
.Font.Bold = True
.Font.Size = 11
'.HorizontalAlignment = xlCenterAcrossSelection
End With
Excel.Cells.Select
Excel.Cells.EntireColumn.AutoFit
Excel.Range("A1:K2").Select
With Excel.Selection.Interior
.ColorIndex = 15
End With
Excel.Range("L1:W2").Select
With Excel.Selection.Interior
.ColorIndex = 6
End With
Excel.Range("X1:X2").Select
With Excel.Selection.Interior
.ColorIndex = 2
End With
Excel.Range("Y1:AK2").Select
With Excel.Selection.Interior
.ColorIndex = 43
End With
With Excel.Selection.Borders(xlEdgeTop)
.Weight = "$00000004"
.LineStyle = -4119
.ColorIndex = -4105
End With
With Excel.Selection.Borders(xlEdgeLeft)
.Weight = "$00000004"
.LineStyle = -4119
.ColorIndex = -4105
End With
With Excel.Selection.Borders(xlEdgeRight)
.Weight = "$00000004"
.LineStyle = -4119
.ColorIndex = -4105
End With
With Excel.Selection.Borders(xlEdgeBottom)
.Weight = "$00000004"
.LineStyle = -4119
.ColorIndex = -4105
End With
Excel.Range("A2:AK2").Select
Excel.Selection.Font.Size = 11
Excel.Selection.HorizontalAlignment = xlCenter
Excel.Range("A1:A1").Select
Excel.Columns("l:w").Select
Excel.Selection.NumberFormat = "#,##0.00;[Red](#,##0.00)"
Excel.Columns("y:ak").Select
Excel.Selection.NumberFormat = "#,##0.00;[Red](#,##0.00)"
ExcelWBK.SaveAs FileName:=X & vNome & ".xlsx"
Excel.Application.DisplayAlerts = True
Set ExcelWS = Nothing
Set ExcelWBK = Nothing
End If