Report Items not showing in report header in Print Layout view
I have created an SSRS 2005 report in VS2005, and placed this code in the code window of the report properties: Public Function GetSchoolName(ByVal strSchoolName As String) As Object If strSchoolName <> "" Then GetSchoolName = strSchoolName Else GetSchoolName = "" End If End Function Then, from a textbox in the header, it successfully displays the school name in report run time: = Code.GetSchoolName(ReportItems!SchoolLongName.Value) However, when you click on Print Layout in the preview pane, or use the print preview in Report Manager, the school name does not appear. Is there a way to have the report item show in the header? I believe this works on a 2008 reporting server, but we must deploy to a 2005 reporting server. Thank you, Elaine
May 17th, 2011 12:24pm

Hi eshafer, According to your description, this is a known issue in SSRS 2005. I suspect that the reason is that the Body and Header are calculated in separate passes and thus have no real relation to each other. This is also why referring to report items won't work. I suggest you adding the field to the Body of the report (but hide it), and then use the ReportItems! Textboxname.value as parameter in the header to refer to the field in the Body. Further details about ReportItems: Using the ReportItems Collection References in Expressions (Reporting Services): http://msdn.microsoft.com/en-us/library/bb934329.aspx If you have any question, please feel free to ask. Thanks, Eileen
Free Windows Admin Tool Kit Click here and download it now
May 23rd, 2011 2:32am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics