mobile databases, mobile forms, and mobile synchronization … where you need to work
Providing Pocket Access, Mobile Database, Windows CE Database, and Windows CE Development Solutions

Tip of the Month (January 2009)

Generating File Names for Export Files

By default, when Visual CE does an OPTION | EXPORT, the name of the export file is the name of the table with a .TXT extension. If you export a second time, the new export will overwrite the previous one.

You might want to export periodically but not lose your previous exports. For example, you may want to export your orders once a day. To do this, you need to specify then name of the file to export to. You do this by running a macro with two steps:

        Set "Value" to @year(@now) & '-' & @month(@now) & '-' & @dayofmonth(@now) & '.txt'
        Set "Col" to @var(10)
        Set "File" to @var(10)

When you run the macro, the filename will be derived from the current date. For example, the filename may be 2009-1-15.txt

Previous Tips of the Month