You can export Access database objects in a variety of formats. The specific formats available depend on the object you are trying to export. Tables, for example, can be exported in pretty much the same formats in which they can be imported. Macros, on the other hand, can be exported only to another Access database.
The following table lists the export formats available for each object:
Object | Export formats |
---|---|
Table | Access, dBASE, Excel, HTML, Lotus 1-2-3, Paradox, Text, SharePoint Team Services, Active Server Pages (ASP), Microsoft Internet Information Server (IIS), Rich Text Format (RTF), Word Merge, XML, Open Database Connectivity (ODBC) |
Query | Access, dBASE, Excel, HTML, Lotus 1-2-3, Paradox, SharePoint Team Services, Text, ASP, IIS, RTF, Word Merge, XML, ODBC |
Form | Access, Excel, HTML, Text, ASP, IIS, RTF, XML |
Report | Access, Excel, HTML, Text, RTF, Snapshot, XML |
Page | Access, Data Access Page (DAP) |
Macro | Access |
Module | Access, Text |
Tables and queries can be exported to most versions of the listed formats. Forms and reports are more limited, but even so, exporting to the formats you are most likely to use is pretty straightforward. The ones that get a little tricky are Active Server Pages (ASP), Microsoft Internet Information Server (IIS), and Open Database Connectivity (ODBC).
In this exercise, you will export the Suppliers table from the GardenCo database in a format that can be used by Excel. Then you’ll export the Customers table to an XML document.
USE the GardenCo database in the practice file folder for this topic. This practice file is located in the My DocumentsMicrosoft PressAccess 2003 SBSImportingExport folder and can also be accessed by clicking Start/All Programs/Microsoft Press/Access 2003 Step by Step.
OPEN the GardenCo database and acknowledge the safety warning, if necessary.
In the database window, click the Suppliers table.
On the File menu, click Export to display the Export Table ’Suppliers’ To dialog box.
In the Save as type list, click Microsoft Excel 97-2003.
Access inserts the name of the table (Suppliers) in the File name box.
Click Export.
Navigate to the My DocumentsMicrosoft PressAccess 2003 SBSImportingExport folder, and double-click Suppliers to view the new worksheet in Excel.
Quit Excel.
Click the title bar of the database window to activate it, and with the Suppliers table still selected, on the File menu, click Export.
Navigate to the My DocumentsMicrosoft PressAccess 2003 SBSImportingExport folder, click XML in the Save as type box, accept Suppliers as the file name, and then click the Export button to open the Export XML dialog box.
Access 2003 has been updated to comply with the 2001 XML Schema recommendation described at www.w3.org/2001/XMLSchema. You can therefore export data from Access in an XML format that can be used by other applications that are also in compliance. This makes it possible for you to output XML data that can be used by Visual Studio .NET programs.
Make sure both Data (XML) and Schema of the data are selected, and then click OK.
Press to switch to Windows Explorer, and notice that Access exported the Suppliers table as both an .xml and an .xsd file.
Repeat steps 8 and 9 and try exporting the Suppliers table in various other formats by changing the options in the Save as Type box. Then view the exported files to see the results.
CLOSE the GardenCo database and close Windows Explorer.