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 Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Conditional report title formula

Status
Not open for further replies.

TerriO

Technical User
Jan 9, 2002
84
US
Having trouble getting this report title to only print the Campaign name when the salesperson is null, it still puts in the Salesperson:"

if not isnull({?@SALESPERSON}) then ("Salesperson: "+{?@SALESPERSON}) + "Campaign: " + {@Report Title Line 3 Formula}
else "Campaign: " +{@Report Title Line 3 Formula}

Current result if Salesperson is null is :

Salesperson: Campaign: Purchase Follow Up

I don't want Salesperson Printed unless a value for the salesperson Parameter is entered.


Terri
 
An empty string is not equal to NULL. Try
if not isnull({?@SALESPERSON}) and len ({?@SALESPERSON}) > 0 then .....
 
Or:

if isnull({?@SALESPERSON}) or trim({?@SALESPERSON}) = "" then
"Campaign: " +{@Report Title Line 3 Formula}
else
("Salesperson: "+{?@SALESPERSON}) + "Campaign: " + {@Report Title Line 3 Formula}

-k
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top