This method loads the specified report template into the Report window.
Visual Basic |
---|
Public Function LoadReportTemplate( _ ByVal FileName As String _ ) As Long |
- FileName
- This required String value specifies the pathway and filename of the template to load into the Report window.
Long value. This returns -1 (or True) if the function succeeds and 0 (or False) if it does not.
Sub Main
Dim App As Object
Dim PartProg As Object
Dim RepWin As Object
Set App = CreateObject("Pcdlrn.Application")
Set PartProg = App.ActivePartProgram
Set RepWin = PartProg.ReportWindow
' Loads the TEXTONLY.RTP report template.
RepWin.LoadReportTemplate "C:\PCDMIS43RC2\REPORTING\TEXTONLY.RTP"
RepWin.RefreshReport
End Sub