Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Print title with empty table
Message
General information
Forum:
Visual FoxPro
Category:
Reports & Report designer
Miscellaneous
Thread ID:
00609558
Message ID:
00609589
Views:
14
>Hi,
>
>I'm using a report based on a SQL-SELECT statement into
>a cursor. Sometimes no records are selected. In this case
>VFP simply prints nothing. Is there a way to get the report
>at least printing a header or title?
>
>I thought about adding a blank record to the cursor as a workaround.
>
>Thanks.
>
>Andreas

Why would you want to print a report that shows nothing? You could just query the _TALLY command after your SELECT and if no records are found then inform the user via a message box.

If you still wish to have a title print with nothing you could make the CURSOR updateable (If you are using VFP7) or select to a temporary table. Based upon the _TALLY you could append a blank record to the cursor/table. You can put some code in your report that when it finds appended data it prints what you want.
Bret Hobbs

"We'd have been called juvenile delinquents only our neighborhood couldn't afford a sociologist." Bob Hope
Previous
Reply
Map
View

Click here to load this message in the networking platform