data report of vb6 - page header problem...
i have a report wherein some data in the page header section change everytime the value of a certain field changes...
example:
the data is grouped by batch#....
if batch# field's value = 001
the header becomes = 'RECEIPTS REGISTER'
if the value = 002
the header becomes = 'INVENTORY SUMMARY'
... AND so on....
the batch# is in the details section...
the header is in the page header section....
then, after every changes in batch# field, there is a page break...
how will i manipulate it? i am using vb6's data report... anybody help me out? i really need it badly....
Re: data report of vb6 - page header problem...
Try this!
VB Code:
Dim rptDataReport As DataReport1
Dim strHeader As String
Set rptDataReport = New DataReport1
If BatchNo = "001" Then
strHeader = "RECEIPT REGISTER"
Else
strHeader = "INVENTORY SUMMARY"
End If
rptDataReport.Sections("Section4").Controls.Item("lblHeader").Caption = strHeader
rptDataReport.Show
Re: data report of vb6 - page header problem...
BTW, you should have a rptLable in the header section (Section4) of the datareport and name it "lblHeader". Or whatever you call it....
Re: data report of vb6 - page header problem...
Moved to reporting section
Re: data report of vb6 - page header problem...
Quote:
Originally Posted by boyet0911
BTW, you should have a rptLable in the header section (Section4) of the datareport and name it "lblHeader". Or whatever you call it....
thanks for that but i dont think it will work the way i want it.
i want a report wherein everytime the batch# changes,
it will print to the next page and its header changes too....
how can i do this?
Re: data report of vb6 - page header problem...
anybody please help. i really need this badly... how can i manipulate the header... any suggestions? except for the "caption" method suggested above.... i already tried it... and it doesn't work the way i want it.... help...
Re: data report of vb6 - page header problem...