This task schedules and submits a job to run automatically, regardless of whether ENVI is open.

To learn more about running ENVITask jobs this way, see Run Models on a Schedule.

Example


; Start the application
e = ENVI(/HEADLESS)
 
; Get the task from the library of ENVITasks
task = ENVITask('SubmitScheduledJob')
 
; Specify the task to run
task.input_task = ENVITask('GetVersion')
 
; Specify how often
task.schedule_type = 'Once'
 
; Specify when to run
task.start_time = '23:00'
 
; Run the task
task.Execute

Syntax


Result = ENVITask('SubmitScheduledJob')

Input parameters (Set, Get): END_DATE, END_TIME, FREQUENCY, LABEL, INPUT_TASK, SCHEDULE_TYPE, START_DATE, START_TIME

Output parameters (Get only): LOG, JOB_ID

Parameters marked as "Set" are those that you can set to specific values. You can also retrieve their current values any time. Parameters marked as "Get" are those whose values you can retrieve but not set.

Input Parameters


END_DATE (optional)

The date the job must stop running. The format must be mm/dd/yyyy. If not set, the task will run indefinitely.

END_TIME (optional)

The time the job must end running. The format must be hh:mm (24-hour). This applies only to Minute and Hourly schedules.

FREQUENCY (optional)

How often to run the job. The units and range used will depend on the specified SCHEDULE_TYPE:

  • Minute: 1 to 1439 minutes. The default is 1 minute.
  • Hourly: 1 to 23 hours.
  • Daily: 1 to 365 days.
  • Weekly: 1 to 52 weeks.
  • Monthly: 1 to 12 months.

LABEL (optional)

A short string to help identify or describe the job.

INPUT_TASK (required)

Specify the task that will be submitted to run on a schedule.

SCHEDULE_TYPE (optional)

Specify the schedule type with one of the following. Use the FREQUENCY parameter to specify the units and range of the schedule type.

  • Once: Run a one-time execution at a specific date/time.
  • Minute: Run the task every n minutes.
  • Hourly: (default) Runs every n hours.
  • Daily: Run once per day or every n days.
  • Weekly: Run every n weeks.
  • Monthly: Run every n months.

START_DATE (optional)

The date the job must start running. The format must be mm/dd/yyyy. If not set, it will default to 'today'.

START_TIME (optional)

The time the job must start running. The format must be hh:mm (24-hour).

Output Parameters


LOG

The system response after the job has been submitted, for tracking and debugging purposes.

JOB_ID

The resulting job ID.

Methods


Execute

Parameter

ParameterNames

Properties


DESCRIPTION

DISPLAY_NAME

NAME

REVISION

TAGS

Version History


ENVI 6.3

Introduced

See Also


ENVITask, Run Models on a Schedule