Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

This feature is new in Ignition version 7.8.0
Click here to check out the other new features


Returns a specific schedule.


  • Parameters

String scheduleName - The name of the schedule to return. Case-sensitive

  • Returns

AbstractScheduleModel - The schedule, which can be a BasicSchedule, CompositeSchedule, or another type registered by a module, or None if not found.

  • Scope


Code Examples
Code Snippet
# This example will get a schedule and print info about it:
# This function handles recursive printing of the different schedule types. Modules can register more types than listed here.
def printScheduleInfo(aSchedule):
	if aSchedule.getType() == "basic schedule": 
		print "Basic schedule type: ",aSchedule.getName(), aSchedule.getDescription(), aSchedule.isAllDays(), aSchedule.isObserveHolidays()
	elif aSchedule.getType() == "composite schedule":
		compositePieces = aSchedule.getModels()
		print "Composite schedule type:",aSchedule.getName(), aSchedule.getDescription(), " which is made up of..."
		for piece in compositePieces:
		print "Other schedule type: ", aSchedule.getName(), aSchedule.getDescription(), aSchedule.getType(), aSchedule.isObserveHolidays()
# The main function
scheduleName = "MySchedule"
schedule = system.user.getSchedule(scheduleName)
if schedule == None:
	print "Schedule", scheduleName, "was not found"
Basic schedule type:  MySchedule A description False True
  • No labels