Import/Export functions

These are a few import/export routines (some of which are classes, and some normal modules) which I stuck together into one MS Access .MDB for distribution purposes.

I find it handy to have this code always available whereever I am. If you have any idea about people who find code like this useful / places where it should get better exposure, you can tell me.

ExcelReport

The ExcelReport class is used to create reports in MS Excel. It's usable 'as is' in VB and VBA (MS Access).

The main reason for creating a class for this instead of a regular module, is that Excel can be made invisible during report generation, without problems. When the class instance goes out of scope, Excel is always made visible again. Also, some other properties can be set and (their old values) remembered.
(The reason for making Excel invisible during report generation is speed, and also users should not be able to accidentelly alter the Excel report while it's being built.)

It is not well documented. There are some comments inside the module, and there's a specification in MS Word format in the below zip file, but that's outdated. If you really want me to do something about it, ask me :-)

ExcelImport

The ExcelImport class can import data tables from Excel sheets (according to predefined specifications if need be), and is useful in circumstances where the 'standard MS Access import routine' does not suffice.

This module is documented with inline comments which are also recompiled in a HTMLHelp file.

basAsciiFile

This module contains a function ImportAscii(), to import data from text files (delimited or fixed width), according to predefined specifications. It's useful in cases where the 'standard MS Access import routine' does not suffice, or when you want the input specification in a normal table instead of 'hidden away' inside MS Access.

There's also a function ExportAscii() to export data to a text file.

dependencies

Several optional dependencies (like a form containing a progress bar) are also present in the MDB file. Each of the three mentioned classes/modules has comments at the top, about which dependencies they have.

AttachmentSize
ImportExport.zip352.71 KB