

Each object will be represented by the variable taskDataObj as the array of objects is iterated.Ġ5 Create a new OmniFocus task using the title of the corresponding OmniPlan task extracted from the passed-in object using the key: "OPtaskTitle"Ġ6 Generate a link URL to the created task and store it in the variable: OFtaskLinkĠ7 Set the value fo the created task's note using the notes of the corresponding OmniPlan task extracted from the passed-in object using the key: "OPtaskNote"Ġ8 Create a date object using the date string representing the end date value of the OmniPlan task. *Ġ1-20 The function for creating new tasks in OmniFocus using the OmniPlan task data.Ġ2-19 The script is placed within JavaScript error handlers (try, catch, throw) so that any problems in the script execution are displayed to the user in OmniPlan.Ġ3 Create an empty array to contain links to the created OmniFocus tasks that will be returned to the calling function so that each link can be added to the notes field of its originating OmniPlan task.Ġ4-13 Use the forEach(…) JavaScript function to process each of the OmniPlan task data objects within the array of objects contained in the input parameter ( arg). Copy Selected Tasks to OmniFocus Copy Download Plug-In Here is the OmniPlan action for creating a new tasks in OmniFocus using parameters of the OmniPlan selected tasks. Clicking or tapping this link will cause the created task to be displayed within OmniFocus.Ħ The end date of the the OmniPlan task is used as the due date for the created OmniFocus task.


1 The task selected in the OmniPlan project.Ģ The task created by the script within OmniFocus.ģ The text of the selected task’s note is assigned to the created OmniFocus task.Ĥ The name of the OmniPlan document is prepended to the note body of the created task, and is added as a tag to OmniFocus (if it doesn’t already exist).ĥ A link to the OmniFocus task is appended to the note of the selected OmniPlan task.
