The information in this article applies to:
- Microsoft Access versions 7.0, 97
SYMPTOMS
Novice: Requires knowledge of the user interface on single-user computers.
When you print to a file using the Print To File option in the Print
dialog box, the file created with a Generic/Text Only printer driver
contains characters not supported by Microsoft Windows 95.
RESOLUTION
There are two ways to work around this behavior. One way is to use the
Print To File option in the Print dialog box, and then to edit the file
manually by deleting the unsupported ASCII characters. However, the
recommended way is to output the file to a text file. The following steps
demonstrate this method:
- Open the sample database Northwind.mdb.
- Click the Reports tab, and then click New. In the New Report dialog box,
click Design View, base the new report on the Categories table, and
then click OK.
- If the Field List box is not displayed, click Field List on the
View menu,.
- Drag the CategoryName field to the report's detail section.
- Close and save the report as Report1.
- Click the Macros tab, click New, and create the following macro:
Macro Action
------------
OutputTo
Macro1 Actions
--------------------------
Object type: Report
Object name: Report1
Object format: MS-DOS Text
Output file: C:\test.txt
Auto Start: No
- Close and save the macro as Macro1.
- On the Tools menu, click Macro. In the Run Macro dialog box, select
Macro1, and then click OK.
- Open the C:\Test.txt file in Notepad or another text editor. Note
that there are no unsupported ASCII characters in the test.txt file
and that the spacing between the controls is close to what it was in
Microsoft Access Print Preview.
MORE INFORMATION
The text file that the Print To File option creates contains unsupported
ASCII characters in Microsoft Windows 95, and the formatting of the report
does not resemble what you see in Print Preview in Microsoft Access.
Steps to Reproduce Behavior
- Open the sample database Northwind.mdb.
- Click the Reports tab, and then click New. In the New Report dialog
box, click Design View, base the new report on the Categories table,
and then click OK.
- If the Field List box is not displayed, click Field List on the
View menu,.
- Drag the CategoryName field to the report's detail section.
- On the File menu, click Print.
- In the Print dialog box, select the Generic/Text Only printer driver.
After selecting the Generic/Text Only driver, click Print To File, and
then click OK.
NOTE: If you do not have the Generic/Text Only driver installed, you
must install the driver. Steps to install the Generic/Text Only printer
driver are outlined in the "Steps to Install Printer Driver in
Windows 95" section.
- When prompted, name the file, and then click OK.
- After the file has been saved, open the file in Notepad or another text
editor. Note that there are unsupported characters. Also note that the
file's formatting does not resemble the report's spacing in Microsoft
Access.
Steps to Install Printer Driver in Windows 95
- Click the Windows 95 Start button, point to Settings, and then
click Printers.
- Double-click the Add Printer icon. The Add Printer Wizard starts.
- Click Next in the Wizard startup screen.
- Click Next again.
- When prompted for a printer type, select Generic under the
Manufacturers heading, and Generic/Text Only under the Printers
heading. After selecting the manufacturer and printer, click Next.
- Click Next to accept the default printer port.
- Click Next to accept the default printer name and settings.
- Select No to print a test page, and then click Finish to have the
wizard install the files for a Generic/Text Only printer driver.
REFERENCES
For more information about the OutputTo method, search for "OutputTo
Method" using the Microsoft Access Help Index.
|