Repository.Task.AddScheduledTask: Difference between revisions
Jump to navigation
Jump to search
Alex Ulanov (talk | contribs) |
Kate Racaza (talk | contribs) No edit summary |
||
Line 1: | Line 1: | ||
{{Template: | <noinclude>{{Template:API}}{{Template:APIBreadcrumb|10|Repository}}</noinclude> | ||
{{Template:Repository | |||
==Syntax== | Saves a new [[CScheduledTask Class|cScheduledTask]] object to the Synthesis repository. Returns a '''Boolean''' value; when true, indicates that the scheduled task now exists in the repository. | ||
<noinclude> | |||
== Syntax == | |||
''object''.'''Task.AddScheduledTask(''task'')''' | |||
where ''object'' is a variable that represents a Repository object. | |||
== | === Parameters === | ||
{{APIComment|' | {| {{APITable}} | ||
Dim | |- | ||
|task{{APIParam|Required}}||The [[CScheduledTask Class|cScheduledTask]] object to be added. | |||
{{APIComment|' | |} | ||
== Example == | |||
{{APIComment|' | '''VBA''' | ||
{{APIPrefix|Dim}} MyRepository {{APIPrefix|As New}} Repository | |||
{{APIComment|...'Add code to connect to a Synthesis repository.}} | |||
{{APIComment|'Create a new scheduled task. The following example creates a task named "MyNewTask."}} | |||
{{APIPrefix|Dim}} NewTask {{APIPrefix|As New}} cScheduledTask | |||
NewTask.Name = {{APIString|"MyNewTask"}} | |||
{{APIComment|'Add the new task to project #1. The task will be visible in the Synthesis repository upon refresh.}} | |||
MyRepository.Project.SetCurrentProject(1) | |||
{{APIPrefix|Call}} MyRepository.Task.AddScheduledTask(NewTask) | |||
'''VB.NET''' | |||
{{APIPrefix|Dim}} MyRepository {{APIPrefix|As New}} Repository | |||
{{APIComment|...'Add code to connect to a Synthesis repository.}} | |||
{{APIComment|'Create a new corrective task. The following example creates a corrective task named "MyNewTask."}} | |||
{{APIPrefix|Dim}} NewTask {{APIPrefix|As New}} cScheduledTask ({{APIString|"MyNewTask"}}) | |||
{{APIComment|' | {{APIComment|'Add the new task to project #1. The task will be visible in the Synthesis repository upon refresh.}} | ||
MyRepository.Project.SetCurrentProject(1) | |||
MyRepository.Task.AddScheduledTask(NewTask) | |||
</noinclude> | |||
Revision as of 22:26, 16 July 2015
Member of: SynthesisAPI10Repository
Saves a new cScheduledTask object to the Synthesis repository. Returns a Boolean value; when true, indicates that the scheduled task now exists in the repository.
Syntax
object.Task.AddScheduledTask(task)
where object is a variable that represents a Repository object.
Parameters
Name | Description | |
---|---|---|
taskborder="0" cellpadding="5" cellspacing="0" style="border-collapse: collapse; text-align: left; cellborder" | ||
Name | Status | The cScheduledTask object to be added. |
Example
VBA Dim MyRepository As New Repository ...'Add code to connect to a Synthesis repository. 'Create a new scheduled task. The following example creates a task named "MyNewTask." Dim NewTask As New cScheduledTask NewTask.Name = "MyNewTask" 'Add the new task to project #1. The task will be visible in the Synthesis repository upon refresh. MyRepository.Project.SetCurrentProject(1) Call MyRepository.Task.AddScheduledTask(NewTask)
VB.NET Dim MyRepository As New Repository ...'Add code to connect to a Synthesis repository. 'Create a new corrective task. The following example creates a corrective task named "MyNewTask." Dim NewTask As New cScheduledTask ("MyNewTask") 'Add the new task to project #1. The task will be visible in the Synthesis repository upon refresh. MyRepository.Project.SetCurrentProject(1) MyRepository.Task.AddScheduledTask(NewTask)