Hello,
Im a bit confused with a debug im getting. The code im running is very simple and works in my 2003 database (Im transferring to 2007).
Below is the code. The Path and FileName are both being read correctly. FOr some reason its giving a compile error variable not defined. Its highlighting the table i want to export (the table does exist and ive checked name/spelling). Does anyone know what could be wrong?
Thanks
DoCmd.TransferSpreadsheet acExport, acSpreadsheetTypeExcel9, tbl_MyTable, Path & FileName
Im a bit confused with a debug im getting. The code im running is very simple and works in my 2003 database (Im transferring to 2007).
Below is the code. The Path and FileName are both being read correctly. FOr some reason its giving a compile error variable not defined. Its highlighting the table i want to export (the table does exist and ive checked name/spelling). Does anyone know what could be wrong?
Thanks
DoCmd.TransferSpreadsheet acExport, acSpreadsheetTypeExcel9, tbl_MyTable, Path & FileName