Closed rluech closed 6 years ago
Interesting question, I normally don't use these schedules, but I've changed the package so that this is now possible. The following below schedules on sunday and saturday e.g. I have the impression that you need locale specific days of week. Can't check that as I've set my windows machine on a english locale. If you have another language, you probably need to change the days to your locale.
Please test using the current version of the package on github and let me know if it worked.
taskscheduler_create(taskname = "myfancyscript_sunsat", rscript = myscript,
schedule = "WEEKLY", starttime = "09:10", days = c('SUN', 'SAT'))
Cool, it seems to work. Thanks devtool::install_github("bnosac/taskscheduleR") (after initial errors / conflict with data.table) taskscheduler_create(..., days = c("MON",TUE", ...)) now accepts a Character vector length > 1 cmd taskschd.msc on German Windows 10 displays a propper task as intended, so english input seem correctly interpreted. Will see definately the after weekend.
Great. Let me know if it worked for your setting next week. The same logic was implemented if you want to schedule only certain months in the monthly setting.
If this worked, can you close the issue?
I didn't forget to give feedback. But, unfortunately I have to tell the Windows taskschedualer to run even if the user is logged off. This was not the case before, but my user account get changed I think, running with admin rights now.
For user logged off, have you tried https://github.com/bnosac/taskscheduleR/issues/44
sorry havent seen that, its written in your documentation. Yes I guesst that's it.
Ok, the taskscheduler now runs as intended, from Mo to Fr omitting Sa/So. Thanks!
Very handy package, thanks! How can I specify the script to run from Monday to Friday but not on Weekends? According to the error message days = only takes a length one character vector:
By the way, does the language of the locale matter as we specify english lables