Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Preview with ReportListener
Message
General information
Forum:
Visual FoxPro
Category:
Reports & Report designer
Environment versions
Visual FoxPro:
VFP 9
OS:
Windows XP
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01030818
Message ID:
01030858
Views:
13
Check out the reportlistener's printjobname property. If you look in the XSource for the ReportPreview source you'll see the project and inside of there is a form class inside of frxpreview.vcx called frxpreviewform. In the show event of that form class is the following...
*-----------------------------------
* Set and save the current form caption for later
* (See THIS.synchPageNo())
*-----------------------------------
if empty( THIS.Caption )
	THIS.Caption = REPORT_PREVIEW_CAPTION
endif

if not empty( THIS.oReport.PrintJobName)
	THIS.Caption = THIS.Caption + " - " + THIS.oReport.PrintJobName
else
	THIS.Caption = THIS.Caption + " - " + THIS.frxFilename 
endif		
THIS.formCaption     = THIS.Caption
...so if you still don't like it after setting the property of your report listener then go into XSource and change the code I posted above and recompile the reportpreview.app


>I did some Previews and found that the Caption for the preview window not only has the caption a put on it but it adds the name of the report too, which I don't like, I don't want my customers to see that.
>
>The code is this
>
>******************
>PARAMETERS oReportListener
>
>* oVP - creo y seteo el objeto Preview
>oVP = NULL
>DO (_REPORTPREVIEW) with oVP
>
>* set initial properties of the preview window:
>oVP.caption = THIS.cNombreVentana
>
>* dimensiona la ventana de preview
>THIS.hw(oVP)
>
>* Assign our Preview container to the listener:
>oReportListener.PreviewContainer = oVP
>
>REPORT FORM (THIS.cNombreReport) OBJECT oReportListener
>**********************
>and the preview window ends up with a caption like this:
>
>"My caption " + " - " + "MyReportsName"
>
>Is there a way to have only my caption, and not the ReportsName?
>Thanks
>Hernan
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform