Apple Newton Utilities Guia do Utilizador Página 698

  • Descarregar
  • Adicionar aos meus manuais
  • Imprimir
  • Página
    / 942
  • Índice
  • MARCADORES
  • Avaliado. / 5. Com base em avaliações de clientes
Vista de página 697
CHAPTER 19
Built-in Applications and System Data
19-24 To Do List
Also, note that some of these methods only work when the To Do List is open. You
can ensure the To Do List is open by calling the Dates method
DisplayDate
passing in
'toDoList for the format parameter as in the following code:
//open Dates and make it show today’s To Do List
GetRoot().calendar:Open();
GetRoot().calendar:DisplayDate(time(),'toDoList);
This section describes
creating and removing To Do tasks
accessing tasks
checking-off tasks
using miscellaneous To Do List methods
using the To Do List soup
Creating and Removing Tasks 19
There are two To Do List methods that add a task: CreateToDoItem and
CreateToDoItemAll. The CreateToDoItem method takes four parameters, as
in
CreateToDoItem(date,richString,reminder,frequency). The
CreateToDoItemAll method takes two additional parameters, priority and
completed, which set the priority and completion status of the new task.
The following code example adds a task to today’s To Do List:
GetRoot().calendar:GetToDo():CreateToDoItem (time(),
"test", nil, nil);
The To Do List GetToDoEntry method (discussed in “Accessing Tasks” beginning
on page 19-24) will also create a soup entry if one does not exist for that date.
To remove tasks, use the To Do List method
RemoveOldToDoItems, which
removes either all or those tasks that have been marked-off before a specic date.
The following code sample removes all the nonrepeating To Do List tasks in the
twentieth century:
GetRoot().calendar:GetToDo():
RemoveOldToDoItems(StringToDate("1/1/2000"),'all,nil);
Accessing Tasks 19
The To Do List provides three methods for accessing tasks:
GetToDoItemsForThisDate
GetToDoEntry
GetToDoItemsForRange.
Vista de página 697
1 2 ... 693 694 695 696 697 698 699 700 701 702 703 ... 941 942

Comentários a estes Manuais

Sem comentários