Access VisualBasic Script

Public Sub ExportTable()
   DoCmd.OutputTo acOutputTable, "tblCustomer", acFormatXLS, _
                  "C:\BegVBA\Customer.xls"
End Sub