Reporting ServicesSQL Server Reporting Services. Please specify which version.
Welcome to the p2p.wrox.com Forums.
You are currently viewing the Reporting Services section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
I'm trying to display some address information on a billing invoice like so...
Name
CompanyName
AddressLine1
AddressLine2
City, State Zip
If AddressLine2 doesn't have any data, I want to print City, State, and Zip in it's place. I created this expression which doesn't have any syntax issues but displays #Error when the report is generated. I also tried adding Table and List Item data regions and removing the dataset from the expression but it still returns #Error.
Since #Error isn't very intuitive, I was wondering if anyone could tell me what is wrong with my expression.
Taking out the Len() function and checking for the value = "" works. This wouldn't work of course, if the field was returning NULL but then you should be able to use the IsNothing() function instead.
I'm sure there's a way to use the Len() function without error and I would still like to figure it out but for now I'm going with what works.