The documentation for taskscheduleR::taskscheduler_create
can be found (1) by pressing F1 and clicking on the function call taskscheduler_create
; or (2) on pages 3 and 4 of the manual. Per this documentation, the days
parameter
taskscheduler_create(
...
days = c("*", "MON", "TUE", "WED", "THU", "FRI", "SAT", "SUN", 1:31),
...
)
can be set to days = 1
for schedule = "MONTHLY"
, to trigger on the first day of every month:
character string with days on which to run the script if schedule is ’WEEKLY’
or ’MONTHLY’. Possible values are * (all days). For weekly: ’MON’, ’TUE’,
’WED’, ’THU’, ’FRI’, ’SAT’, ’SUN’ or a vector of these in your locale. For
monthly: 1:31 or a vector of these.
So you'd want to use
taskscheduler_create(taskname = "Rebate Automation2", rscript = myscript,
schedule = "MONTHLY", days = 1, starttime = "12:30")
# ^^^^^^^^