Last active
February 15, 2019 17:28
Star
You must be signed in to star a gist
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Create a new TodoItem instance | |
var newTask = new TodoItem() { | |
Description = "This is a new task we want to add", | |
Content = "The Title for my new task" | |
}; | |
// And add it as task to a project | |
// tasklist id can be left blank, the task will be added to an "Inbox" tasklist | |
// also we can add it as a subtask and assign the parenttask | |
var result = await client.Projects.Projects.AddTodoItem( | |
pTodoItem: newTask, | |
pProjectId: TheProjectId, | |
pTaskListId: TheTaskListId | |
pIsSubTask: IsSubTask | |
pParentTask: ParentTask); | |
//if we want to we can complete our newly created task right away, | |
//the result will be the taskid of the newly created task | |
var ok = await client.Projects.Tasks.CompleteTask(result.Id); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment