Generate Fixed Ascii file

  • Thread starter Thread starter Ken Smith
  • Start date Start date
K

Ken Smith

Is there a way to automate the production of a fixed
length ascii file of fields from a query, some of which
will have leading and some training blank spaces?

If so, I will appreciate advice.
 
Yes.

First, create a query in which you have all of your fields padded
appropriately. Then, after you have saved the query, from the Access menu,
click File|Export. This will invoke the Export Wizard, where you can
follow the prompts to create and save an Export Specification. Last, use
the TransferText (see VBA Help for a description and sample code) method in
VBA code to run your export from the Click event of a Command Button.


hth,
 
Back
Top