NinjaCal

Script Actions

NinjaCal.ScriptActions History

Hide minor edits - Show changes to output

Changed lines 7-8 from:
-->This returns the selected date in $$__NinjaCalSelectedList. If the refocus attribute is set it also snaps the widget to the selected date.
to:
-->This returns the selected date in $$__NinjaCalSelectedList. If the refocus attribute is set it also snaps the widget to the selected date. You can also send a list of ¶ separated dates to select them all. See [[highlighting dates]] for more info.
Changed lines 16-17 from:
--> Same as "selectDate" but takes a range as its contents. Note that the range can be sent as either a quoted pair of ¶ separated dates or a single string with "..." separating start and end dates.
to:
--> Same as "selectDate" but takes a range as its contents. Note that the range can be sent as either a quoted pair of ¶ separated dates or a single string with "..." separating start and end dates. If you're sending  ¶ separated dates, they must be in order with the earliest date followed by the last date.
Changed lines 23-36 from:
stepMonth: params: n

goToDate: params: date

clearDates: params: (none)

'''Examples'''

* To select a single date:
@@Perform Script [ “NinjaCal ( action ; params )”; Parameter
: "selectDate¶" & Get(CurrentDate) ]@@

*To change the focus of the calendar to
a date such as "2/10/2009" (without selecting)
[@Perform Script [ “NinjaCal ( action ; params )”; Parameter: "goToDate¶" & "2/10/2009"
]@]
to:
'''stepMonth''' Parameters: the number of months, usually 1 or -1.

--> Moves the focus of the widget forward and back through the months.

-->Example
: Perform Script [ “NinjaCal ( action ; params )”; Parameter: "stepMonth¶1" ]


'''goToDate''' Parameters:
a date

--> Moves the focus of the widget to the date passed as a parameter-- but does not select the date.

-->Example: Perform Script [ “NinjaCal ( action ; params )”; Parameter: "goToDate¶" & "2/10/2009"
]


'''clearDates''' Parameters: none

--> Clears the selected dates, snapping the focus of the calendar to the current month.

-->Example: Perform Script [ “NinjaCal ( action ; params )”; Parameter: "clearDates"
]
Changed lines 14-18 from:
selectRange : params: daterange; {refocus}
Note: range is either a quoted pair of ¶ separated dates or a single string with "..." separating start and end dates.


to:
'''selectRange''' Parameters: daterange; {refocus}

--> Same as "selectDate" but takes a range as its contents. Note that the range can be sent as either a quoted pair of ¶ separated
dates or a single string with "..." separating start and end dates.

-->Example: Perform Script [ “NinjaCal ( action ; params )”; Parameter:"selectRange" & "¶" & Quote ( List ( RelationshipToEvents::EventDate ) ) & "¶" & "-f" ]

-->Example: Perform Script [ “NinjaCal ( action ; params )”; Parameter: "selectRange¶" & Table::FromDateField & "..." & Table::ToDateField & "¶-f" ]


Changed lines 5-7 from:
'''selectDate'''
Parameters: datelist, {refocus}
to:
'''selectDate''' Parameters: datelist, {refocus}
Changed lines 6-7 from:
 Parameters: datelist, {refocus}
to:
Parameters: datelist, {refocus}
Changed lines 5-16 from:
: selectDate : params: datelist, {refocus}
->returns the selected date in $$__NinjaCalSelectedList

: selectRange : params: daterange; {refocus}
Note: range is either a quoted pair of ¶ separated dates or a single string with "..." separating start and end dates

: stepMonth: params: n

: goToDate
: params: date

:
clearDates: params: (none)
to:
'''selectDate'''
 Parameters
: datelist, {refocus}

-->This returns the selected date in $$__NinjaCalSelectedList. If the refocus attribute is set it also snaps the widget to the selected date.

-->Example: Perform Script [ “NinjaCal ( action ; params )”; Parameter: "selectDate¶" & Get(CurrentDate) ]

-->Example (refocussing)
: Perform Script [ “NinjaCal ( action ; params )”; Parameter: "selectDate¶" & Get(CurrentDate) & "¶-f" ]


selectRange : params: daterange; {refocus}
Note: range is either a quoted pair of ¶ separated dates or a single string with "..." separating start and end dates.



stepMonth: params: n

goToDate: params: date

clearDates: params: (none)
Added lines 1-24:
!!The following script actions are available in NinjaCal...

{ } are for optional parameters

: selectDate : params: datelist, {refocus}
->returns the selected date in $$__NinjaCalSelectedList

: selectRange : params: daterange; {refocus}
Note: range is either a quoted pair of ¶ separated dates or a single string with "..." separating start and end dates

: stepMonth: params: n

: goToDate: params: date

: clearDates: params: (none)

'''Examples'''

* To select a single date:
@@Perform Script [ “NinjaCal ( action ; params )”; Parameter: "selectDate¶" & Get(CurrentDate) ]@@

*To change the focus of the calendar to a date such as "2/10/2009" (without selecting)
[@Perform Script [ “NinjaCal ( action ; params )”; Parameter: "goToDate¶" & "2/10/2009" ]@]

(855) SEEDCODE
[email protected]
Follow us: