Schedule Publication for an Analytic Application

You can schedule a publication for publishing and distributing analytic application views to users or user groups of your choice via email in PDF format at a predefined time or frequency.

Prerequisites

To be able to schedule a publication, you must have the appropriate permission and turned on the mandatory system configuration settings. For detailed information, refer to Schedule Publication Roles and Permissions.

Besides that, to be able to generate PDF for the publication, you must add an ExportToPDF technical object to the analytic application.

Context

You can schedule a publication for both stories and analytic applications. Same as for a story, you can create a single schedule or a recurring schedule. You can later view, modify, or delete an occurrence or a recurrence of the schedule in Calendar.

In this chapter, only the publication settings and configurations specific for the Analytics Designer are listed.

There are two ways of triggering PDF export when scheduling a publication for an analytic application:

  • Automatically generate PDF export. This is the default setting, PDF will be generated automatically when the render of application is considered to completed. In this case, you don’t have to write scripts. An application will be considered fully rendered when the last line of script in the onInitialization event is executed. Any event scripting happened after that will be bypassed.

  • Manually generate PDF export via API. This is the advanced setting that we recommend if you want to control the timing of the PDF export more accurately and not to miss any relevant event scripting happened after the onInitialization event is completed.

    In this case, we recommend you write the following script as the last line of code for the onInitialization event of the Canvas:

    If (Application.isRunBySchedulePublication()) {

    Scheduling.publish();

    }

The two schedule publication settings can be configured in the Styling panel of the Canvas.

Procedure

  1. Use either of the two ways to schedule publication for an analytic application:
    • On the Files page (from main menu, Start of the navigation pathBrowse Next navigation step FilesEnd of the navigation path), select the analytic application that you want to schedule and from the toolbar, select Schedule Publication from (Share).
    • In the application’s run time, from the toolbar, select Schedule Publication from (Share).

    The Schedule Publication dialog box appears.

  2. In the Schedule Publication dialog, by default, the name of the application is automatically filled as the name of the schedule. You can edit the name as you wish.
  3. In the Start field, click to specify the start date and the time you want the schedule to run. Then click Add Recurrence if you want to schedule publication based on a certain recurrence pattern.
  4. In the Subject field, enter the subject of the email.
  5. (Optional) In the Message field, type in a message for the email.
  6. Select the Include Analytic Application Link option, if you want to include in the email a link to navigate email recipients to the analytic application.
  7. To enable application users to customize the values of script variables when opening the application, turn on the option Customize Script Variable.

    Then you can add one or more script variables for application users to customize, as well as define a default value for each of them.

    Note

    Only the variables that are exposed via URL parameters and can be configured via URL will be included.

  8. Add one or more views in the Distribution part to schedule and share customized views of your application or bookmarks of the analytic application. You can specify same or different SAP Analytics Cloud recipients or non-SAP Analytics Cloud recipients for each view.
    Note

    For each view, you’ll have up to 60 seconds to generate PDF export. If the time exceeds that limit, scheduling will skip current task and continue to publish the next view.

  9. (Optional) Edit the name of the PDF file from the File Name field.
  10. Click PDF Settings to configure the PDF settings such as the paper size and choose whether to include appendix or comment or not.
  11. Click OK.

    The schedule is successfully created and is displayed in Calendar.

  12. You can view, modify, or delete an occurrence or a recurrence of the schedule in the Calendar.
  13. To view detailed warning and error messages and system information messages of your schedule publication task, in the Schedule Publication panel of Calendar, click the button (Detailed status).