>Hi Ed and Scott,
>
>I tried moving the NOCONSOLE around and it didn't help. I can get a file created using ASCII but I want to have is a report file in HP format so I can place the file on a diskette or server and have whoever print the report at their discretion. ASCII works but is very ugly.
>
>I tried recreating the report in VFP5 and sending that to a file and the same thing happened, file with 0 bytes and the report going to the printer. I think I must have changed an obscure setting somewhere but haven't a clue what it could be.
Try the following:
Add a new local printer through the Add Printer Wizard. Select the appropriate printer driver for creating output for the HP (if you're trying to be very generic, try the HP Laserjet Series II driver.) When prompted for a port, select FILE:, and give the printer a name (I use HPTOFILE for mine.)
If you give the new printer definition the name HPTOFILE, when you do your REPORT, try the following commands:
SET PRINTER TO HPTOFILE
REPORT FORM G:\DB\SUBD\RPT_ALFA.FRX TO PRINT NOCONSOLE
This will bring up a dialog box that allows you to specify the name and location for the printed output. There are some distinctive advantages to doing this, for example, if you use TrueType fonts that may not be present on the system printing the file after copying it to disk, you can choose to handle TrueType fonts either by downloading them as bitmaps as a part of the output stream, or simply convert the output to a pure graphical format. AFAIK, there's no way to avoid the file selection dialog, unfortunately.
Alternatively, if your default printer is an HP with appropriate format, this might work:
SET PRINTER TO
name of print file to createSET PRINTER TO G:\DB\REPORTS\TEST.TXT
REPORT FORM G:\DB\SUBD\RPT_ALFA.FRX TO PRINT NOCONSOLE
SET PRINTER TO