Importing Database Tables

With the ADOCE control you can copy tables from Microsoft Access .mdb files to an H/PC. Use the Import from Database to Mobile Device dialog box to select which tables and fields to convert to ADOCE databases.

    To import a Microsoft Access database into a device

  1. Connect the device to the desktop computer and open the Mobile Devices window.
  2. Choose Import Database Tables on the Tools menu in the Mobile Devices window.

    An Open dialog box appears.

  3. Select the Microsoft Access .mdb file containing the tables you want to import.

    The Import from Database to Mobile Device dialog box appears. The dialog box lists the tables and fields in the database.

  4. Select the check boxes for the tables and fields you want to import, and clear the check boxes for the tables and fields you do not want to import.
  5. Select the check box for the Read-Only field for the tables you want to make read-only.
  6. Select the Overwrite existing tables and/or data check box if you want to replace tables on the device that have the same name as the tables in the .mdb file.
  7. Choose OK to begin the conversion.

As an option, you can accomplish the same conversion by dragging the .mdb file to the device icon in your Mobile Devices window. This initiates the conversion process. Doing this replaces steps 2 and 3 in the procedure.

The Import from Database to Mobile Device dialog box includes the following features:

For each .mdb file imported, the converter generates a log file named Db2ce.txt in the partner directory for the H/PC, usually in C:\Program Files\Windows CE Services\Profiles\devicename.

You may also choose to import tables from an ODBC data source.

    To import data from an ODBC data source into a device

  1. Connect the device to the desktop computer and open the Mobile Devices window.
  2. Choose Import Database Tables on the Tools menu in the Mobile Devices window.

    An Open dialog box appears.

  3. Choose ODBC Database in the Files of Type list box.
  4. Choose an ODBC data source.
  5. Follow the same procedure for importing a Microsoft Access .mdb file, selecting the tables and fields to import, and other options.

For more information, see Database Conversion Specifics.