Header Ads Widget

LightBlog

Breaking

LightBlog

Friday, June 28, 2013

How to Display value in report Page Header in Nav R2

1. Add Text Box to the body of the report. This will enable us to use it in the Page Header. We add this Text Box in top of the Body.

Value =True
Name =NewPage
Visibility Hidden: “True”
Color: “Red”
-------------------------------------------------------
2. Add Text Box to the body of the report.

Name=PageHeaderData
Visibility Hidden: “True”
Color: “Red”
Value=Fields!CompanyInfo_Address.Value + Chr(177)
+ Fields!CompanyInfo__Address_2_.Value + Chr(177)
+ Fields!CompanyAddr_1_.Value + Chr(177)
+ Fields!CompanyInfo__Phone_No__.Value + Chr(177)
+ Fields!CompanyInfo__Fax_No__.Value + Chr(177)
+ Fields!CompanyInfo__VAT_Registration_No__.Value + Chr(177)
+ Fields!CompanyInfo__Post_Code_.Value + Chr(177)
+ Fields!CompanyInfo_County.Value + Chr(177)
+ Fields!CompanyInfo_City.Value + Chr(177)
+ Fields!CompanyInfo__Country_Region_Code_.Value
-------------------------------------------------------
3. Now add the following code to the Report properties.

Shared Data1 as Object

Public Function SetData(ByVal Value As Object)
    If Not (Value = "") Then
        Data1 = Value
    end If
End Function

Public Function GetData(ByVal Value As Integer) as Object
    Return Cstr(Choose(Value, Split(Cstr(Data1),Chr(177))))
End Function

-----------------------------------------------------------
4.Add text box to Page Header.

Value: “=code.SetData(ReportItems!PageHeaderData.Value)”
Visibility Hidden: “True”
Color: “Red
-------------------------------------------------------
5. Add text box to Page Header.

Value:=code.GetData(1)



No comments:

Post a Comment

Adbox