ReportOptionInfo.Open

Syntax Parameters Return Value
Sub ReportOptionInfo.Open( _
    Option As Variant, _
    ReportLayout As Byte())
  • Option [in]

A Statistica application used to create the report layout.

Type: Variant

  • ReportLayout [in]

Where to create the report layout options to.

Type: Byte()

This function does not return a value.

SVB Example

Adding a report:

Sub Main

    Dim oOM As ObjectManager

    'Reconnect into Enterprise
    Set oOM = New ObjectManager
    oOM.Reconnect Application


    'Create the report
    Dim myReport As OutputMonitor
    Dim myReportInfo As New MonitorCreateInfo
    myReportInfo.Folder = "/Blake's Materials"
    myReportInfo.MonitorType = swcOutputMonitor
    myReportInfo.AuditLogReason = "Adding a report for the Weights Charts"
    myReportInfo.Name = "Weights REPORT"
    Set myReport = oOM.Monitors.AddEx(myReportInfo)
    myReport.AutoSave = False


    'Add an analysis configuration to the report
    myReport.Component.Add(oOM.Monitors.Item("/Blake's Materials/Weights CHARTS"))
    'Set its schedule, starting on February 28, 2017
    myReport.ScheduleInfo.StartDate = #2/28/2017#
    'Schedule it by week, to run at 7:00 PM (the "19" value below),
    'running only on Monday, Wednesday, and Friday (the "1,3,5" value).
    'Refer to OutputMonitorScheduleInfo.ScheduleString for an explanation of this syntax.
    myReport.ScheduleInfo.ScheduleString = "0 19 * * 1,3,5"
    'Note: to make it run on demand, set ScheduleString to an empty string.


    'Set permissions
    myReport.AccessControlList.AddGroup("Administrators", True)
    myReport.AccessControlList.AddGroup("Everyone", False)
    myReport.AccessControlList.AddUser("Blake", True)


    'Set the output options
    Dim reportOutputInfo As New ReportOptionInfo
    reportOutputInfo.Open(Application, myReport.ReportLayout)

    'We will send the output to an HTML report and the printer
    reportOutputInfo.ReportAction = swcReportAction_File + swcReportAction_Print
    reportOutputInfo.OutputFile = "C:\temp\Weights REPORT.htm"
    reportOutputInfo.LaunchAssociatedApplication = True
    myReport.ReportLayout = reportOutputInfo.ReportLayout

    'Save our output changes
    Dim reportUpdateInfo As new MonitorUpdateInfo
    reportUpdateInfo.AuditLogReason = "Setting report's output and scheduling"
    myReport.SaveEx(reportUpdateInfo)

    oOM.Disconnect

    'The report is now ready to be edited interactively.
    'In Enterprise, select the report and click "Edit Report" to format
    'it, and then save it. At this point, you can run the report.

End Sub