Print Page | Close Window

OutputText.mdb (intermediate)

Printed From: Roger's Access Library
Category: Roger's Access Library
Forum Name: Roger's Download Samples
Forum Description: A compendium of Microsoft Access 97 and 2000+ routines, each separated into its own sample database.
Printed Date: 11 Jul 2020 at 6:47pm
Software Version: Web Wiz Forums 12.03 -

Topic: OutputText.mdb (intermediate)
Posted By: Roger Carlson
Subject: OutputText.mdb (intermediate)
Date Posted: 29 Jul 2008 at 10:50pm

Please consider donating $1 per sample downloaded, - find out why here .


This illustrates a simple way to precisely format data for text output. Assuming the following table:

ID  Field1  Field2         Field3         Field4
1   111     1/2/1999    4.2587        3.5%
2   222     1/3/1999    3.598745    5 %

where Field1 is an integer, Field2 is a Date, Field3 is a Single, and Field4 is a Single formatted as percent, and assuming you want the following output:

1,"000111",#Jan 02, 1999#,4.26,00350
2,"000222",#Jan 03, 1999#,33.60,00500

The code in Module1 will produce the called "Table2.txt" in your "My Documents" folder.

Access 97 (23 KB): - uploads/5/
Access 2000 (30 KB): - uploads/5/

Consider donating $1 per sample downloaded," rel="nofollow - find out why here .<

Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.03 -
Copyright ©2001-2019 Web Wiz Ltd. -