D J Horton Consulting Ltd

Personal reference to useful tips and tricks for SQL Server, SQL Server Reporting Services and Crystal Reports.

My alternative to scraps of paper lying about.

Tuesday, 11 October 2016

SSRS custom sort

Public Function CustomSortOrder(ByVal RAG As String) as Integer

Select Case RAG

Case = "Up to 6 month"

Return 1

Case = "7 to 12 months"

Return 2

Case = "More than 12 months"

Return 3

End Select

End Function