Parameters
- jobID
- The ID of the job to get properties
Return Value
The properties of a job
// GetJob returns an existing job // it is passed a valid job ID as an integer var wfCon = await WorkflowModule.ConnectAsync(); var jobManager = wfCon.GetManager<JobsManager>(); var job = jobManager.GetJob(jobID);
// You can change many of the exposed properties of a job and then save them var wfCon = await WorkflowModule.ConnectAsync(); var jobManager = wfCon.GetManager<JobsManager>(); var job = jobManager.GetJob(jobID); job.Description = "This is a test"; job.Save();
// Gets the current step // checks to see if it can execute it // proceeds to do so if it can var wfCon = await WorkflowModule.ConnectAsync(); var jobManager = wfCon.GetManager<JobsManager>(); var job = jobManager.GetJob(jobID); string stepID = job.GetCurrentSteps().First(); if (job.CanExecuteStep(stepID).Item1) job.ExecuteStep(stepID);
Target Platforms: Windows 11, Windows 10, Windows 8.1