Schedule Publication for an Analytic Application
	
	You can schedule publication to distribute analytic application views to selected users or user groups via email at a predefined time or
		with frequency.
		Prerequisites
			To be able to generate PDF for the publication, you must add an Export To PDF technical object to your application.
		 
		Context
			You can create a single or recurring schedule for publication of your application. Later you can view, modify or delete the schedule in
					Calendar.
			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
- 
				Use either of the two ways to schedule publication for an analytic
					application:
				
					
						
							- Go to 
									(Files), select the analytic application
								that you want to schedule and from the toolbar, select   Schedule
										Publication from 
									(Share).  
							- In the application’s run
								time
								(Exit Fullscreen), from the toolbar, select
								Tools
 and choose   Schedule
										Publication. 
						
					 
				 
				
					The Schedule Publication dialog box appears.
				 
			 
- 
				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.
			
 
- 
				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.
			
 
- 
				In the Subject field, enter the subject of the
					email.
			
 
- 
				(Optional) In the Message field, type in a message for
					the email.
			
 
- 
				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.
			
 
- 
				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.
					 
				 
			 
- 
				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.
					 
				 
			 
- 
				(Optional) Edit the name of the PDF file from the File
						Name field.
			
 
- 
				Click PDF Settings to configure the PDF settings such as
					the paper size and choose whether to include appendix or comment or not.
			
 
- 
				Click OK.
				
					The schedule is successfully created and is displayed in
							Calendar.
				 
			 
- 
				You can view, modify, or delete an occurrence or a recurrence of the schedule
					in the Calendar.
			
 
- 
				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).