Text File Problem Please Help

binar

New member
Local time
Yesterday, 19:55
Joined
Oct 18, 2007
Messages
4
What is the best way to export a Report as a text file and not lose any of the straight columns. Currently, my exported text file from Access ends up with columns that are not straight. The padding for the column widths is not accurate. Any help will be greatly appreciated
 
What is the best way to export a Report as a text file and not lose any of the straight columns. Currently, my exported text file from Access ends up with columns that are not straight. The padding for the column widths is not accurate. Any help will be greatly appreciated

Export as fixed width.
 
Reply

Export as fixed width.

Thanks,
But can you elaborate. I have no Fixed Width option in the Export option in Access 2003
 
Thanks,
But can you elaborate. I have no Fixed Width option in the Export option in Access 2003

Actually, you should have it but I'll bet it's where you didn't think to look.

1. Select your table or query to export.

2. Use the drop down in the dialog that appears to select the Text File (*.txt, *.csv,*.tab,*.asc)

3. Click the Export Button.

4. The Export Text Wizard should appear.

5. At the top, click Fixed Width (instead of Delimited) and then you can set your widths.

If you are doing this from code, you will need to do this once manually to create an Export specification that you can refer to in your code. Go here for a quick tutorial (screenshots) on how to create an export specification:

http://www.btabdevelopment.com/main/LinkClick.aspx?link=64&tabid=55&mid=385
 
Reply

Actually, you should have it but I'll bet it's where you didn't think to look.

1. Select your table or query to export.

2. Use the drop down in the dialog that appears to select the Text File (*.txt, *.csv,*.tab,*.asc)

3. Click the Export Button.

4. The Export Text Wizard should appear.

5. At the top, click Fixed Width (instead of Delimited) and then you can set your widths.

If you are doing this from code, you will need to do this once manually to create an Export specification that you can refer to in your code. Go here for a quick tutorial (screenshots) on how to create an export specification:

http://www.btabdevelopment.com/main/LinkClick.aspx?link=64&tabid=55&mid=385


Thanks for the help.

Please allow me to elaborate. Access 2003 seems to have two separate EXPORT commands. The export you are referring to in steps 1 - 5 is the one found when the TABLES button is selected and you have a data table open. The export function found in this mode allows you to select a fixed width via the export wizard.

The other Export command is found when the REPORTS button is selected and a report is open. Since I want my exported TEXT file to mirror the column spacing layout displayed in the REPORT, I'm using the EXPORT command found while in Report Mode. However, this export option does not offer a fixed width option. It basically only offers an Encode Format option selector.

I have tried both export options. Neither seems to give me a Text File Report that mirrors the layout displayed by Access while in Report Mode. Is there any way to make Access run a VBA script that will enable exporting a Text File with high formatting fidelity to the original report displayed in Access?
 

Users who are viewing this thread

Back
Top Bottom