1 Add a report variable cAlias with
Value to store: = cAlias
Initial value: = cAlias
Reset value based on: = Report
Calculation type: = None
2 In the Init event of the Data Environment add
[code Foxpro]cAlias=ALIAS()
LOCAL cNewAlias
cNewAlias=SYS(2015)
IF RECCOUNT(cAlias)=0
SELECT * FROM (cAlias) WHERE .F. INTO CURSOR (cNewAlias) READWRITE
APPEND BLANK
SELECT (cNewAlias)
ENDIF[/code]
3 Select all the objects you want to hide when the cursor has no records, choose Properties and add to Print when expression alias()==cAlias
4 Add a new label with text "Nothing to print" and with the Print when expression alias()!=cAlias
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.