sammi taylor

sammi taylor

  • NA
  • 19
  • 0

String.format expression in C#

Jan 25 2014 3:07 PM
Ist expression works for Person Address in string format in my report field, but if there is no Person address, then pull from Location address:
String.Format("{0}, {1}  {2}",
 Fields!PersonCity.Value,
 Fields!PersonStateCode.Value,
 Fields!PersonZipCode.Value)
 
//Modified to add Location address:
String.Format("{0}, {1}  {2}",
 Fields!PersonCity.Value,
 Fields!PersonStateCode.Value,
 Fields!PersonZipCode.Value), IIF(IsNothing(Fields!LocationCity.Value,
 Fields!LocationStateCode.Value,
 Fields!LocationZipCode.Value))
 
I get BC302015 end of statement expected error.

Answers (3)