Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Report Form printing blank pages...

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
I have a line of code in my program...

REPORT FORM report.frx FOR x = .T. AND y = .T.

Here is the problem, if the FOR conditions aren't met, it prints a blank page. I don't want it to print anything if the conditions aren't met. Any thoughts on how to do this?

Thanks,
mciMonkey
 
Have you tried:
1. Selecting the "Skip Line When Blank" Option(s) or
2. Selecting the &quot;Print When&quot; Option [sig]<p>David W. Grewe<br><a href=mailto:Dave@internationalbid.net>Dave@internationalbid.net</a><br>[/sig]
 
The &quot;Remove Line If Blank&quot; option is checked on all fields.

The thing is, I'm not getting a report with no data fields... I'm getting a blank sheet of paper. The date isn't on the report, the headings aren't there, the report isn't printed at all... but I still get this blank sheet of paper.

I don't want the printer to spit out a blank sheet of paper is the report is empty. I don't want it to do anything if the report is empty.
 
Hi!

Try following:
1. Open your report form
2. RightClick and choose 'Print...'
3. Choose 'Options...' button. You should have report-specific printing options dialog box.
4. Uncheck &quot;Pae eject before&quot; and such checkboxes.

Hope this helped.
[sig]<p>Vlad Grynchyshyn<br><a href=mailto:vgryn@softserve.lviv.ua>vgryn@softserve.lviv.ua</a><br>[/sig]
 
I looked and all of those boxes are already unchecked. :( Any other guesses?
 
What means 'Emoty' report? If it is just no records in report cursor, that check for that before report running and do not run report at all if it is empty. In your case you may check by following way:

LOCATE FOR x = .T. AND y = .T.
IF !EOF()
REPORT FORM ...
ENDIF
[sig]<p>Vlad Grynchyshyn<br><a href=mailto:vgryn@softserve.lviv.ua>vgryn@softserve.lviv.ua</a><br>[/sig]
 
Or wrap your REPORT command in a IF - ?
IF x = .T. AND y = .T.
* my command
ENDIF [sig]<p>John Durbin<br><a href=mailto: john@johndurbin.com> john@johndurbin.com</a><br><a href= </a><br>MCP Visual FoxPro<br>
ICQ VFP ActiveList #73897253[/sig]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top