QuickDevGuide

Home › SSRS Report Development

Expressions & Built-in Functions — SSRS Report Development

Almost every property in SSRS can be an expression — VB.NET-like code starting with =. Collection Example Fields! =Fields!Amount.Value Parameters! =Parameters!StartDate.Value, .Label Globals! =Globals!ExecutionTime, Globals!PageNumber, Globals!TotalPages, Globals!ReportName User! =User!UserID ReportItems! value of another textbox (headers/footers) Common functions Purpose Expression Conditional =IIf(Fields!Margin.Value < 0, "Red", "Black") Multiple cases =Switch(x < 50, "Low", x < 80, "Mid", True, "High") Aggregates with scope =Sum(Fields!Amount.Value, "RegionGroup") Percent of total =Sum(Fields!Amount.Value) / Sum(Fields!Amount.Value, "DataSet1") Running total =RunningValue(Fields!Amount.Value, Sum, "DataSet1") Row banding =IIf(RowNumber(Nothing) Mod 2 = 0, "WhiteSmoke", "White") Lookup…

Key Takeaways