Help: VB6 Data Report - Assign Run-time Label Caption

Help: VB6 Data Report - Assign Run-time Label Caption

Post by Michael Le » Wed, 03 Feb 1999 04:00:00



Is it possible to assign a caption before showing of the data report output
window ?
(Eg: Print out the selection data printing range as selection by the user on
the Report header or Page header)

If yes, how ?

Any help is highly appreciated.

Thanks in advance.

 
 
 

Help: VB6 Data Report - Assign Run-time Label Caption

Post by Kevin Kueble » Fri, 05 Feb 1999 04:00:00



>Is it possible to assign a caption before showing of the data report output
>window ?
>(Eg: Print out the selection data printing range as selection by the user
on
>the Report header or Page header)

>If yes, how ?

Michael,
Sure. Assuming your report is called rptMyReport and you have a variable
called UserName, your code would look something like this:

    rptMyReport.Sections("Header").Controls("lblName").Caption = UserName
    rptMyReport.Show

Just replace the items in quotes with the names of the report section and
label. Notice that the last property (.Caption) won't pop-up with the
auto-complete feature, but it should still work.

Hope this helps,
Kevin Kuebler