scheduled-tasks

Task Scheduler Problem - Run whether user is logged on or not is not working

蹲街弑〆低调 提交于 2021-02-19 03:36:06
问题 I have a batch file which in turn calls VB Script. The task of the VBScript contains a macro whose job is to login into the Oracle db, run few queries, fetch the output in Excel sheet and then it performs other functions. The script is running fine in the scheduler when using the "Run only when user is logged in" option but it doesn't run when "Run whether user logged in or not" option is selected. I tried all the options suggested here in previous posts but none of them worked. 回答1: I

javax.naming.NameNotFoundException: Name [comp/env] is not bound in this Context. Unable to find [comp] error with java scheduler

时光总嘲笑我的痴心妄想 提交于 2021-02-17 19:21:05
问题 What I'm trying to do is to update my database after a period of time. So I'm using java scheduler and connection pooling. I don't know why but my code only working once. It will print: init success success javax.naming.NameNotFoundException: Name [comp/env] is not bound in this Context. Unable to find [comp]. at org.apache.naming.NamingContext.lookup(NamingContext.java:820) at org.apache.naming.NamingContext.lookup(NamingContext.java:168) at org.apache.naming.SelectorContext.lookup

Exception using Process.Start() and Windows Task Scheduler

不羁岁月 提交于 2021-02-17 04:31:32
问题 I wrote C# console app that at some point tries to unzip a file using 7zip (specifically 7za.exe). When I run it manually everything runs fine, but I if I setup a task in Task Scheduler and have it run it throws this exception: System.ComponentModel.Win32Exception (0x80004005): The system cannot find the file specified at System.Diagnostics.Process.StartWithShellExecuteEx(ProcessStartInfo startInfo) at System.Diagnostics.Process.Start() at System.Diagnostics.Process.Start(ProcessStartInfo

Task scheduler / powershell / timeout

妖精的绣舞 提交于 2021-02-11 17:22:14
问题 I have a website which I need to run a script every hour. I set these parameters on task scheduler and it seems to work. Program/script: powershell.exe Add arguments: -c (new-object system.net.webclient).downloadstring('http://www.example.com/test.ashx') The problem is that I have a big loop and processes in this script and the script stops before it finish the loop! Is there any possibility to add a timeout as an argument or something else to prevent this? I'm using Windows Server 2008R2 and

Task scheduler / powershell / timeout

青春壹個敷衍的年華 提交于 2021-02-11 17:22:06
问题 I have a website which I need to run a script every hour. I set these parameters on task scheduler and it seems to work. Program/script: powershell.exe Add arguments: -c (new-object system.net.webclient).downloadstring('http://www.example.com/test.ashx') The problem is that I have a big loop and processes in this script and the script stops before it finish the loop! Is there any possibility to add a timeout as an argument or something else to prevent this? I'm using Windows Server 2008R2 and

Facing error when python exe service is started after nssm

对着背影说爱祢 提交于 2021-02-11 15:07:57
问题 I have a situation where i have to run a python.exe as a service in NSSM. To test, I have created .exe file which has only import pandas as pd in it. I created the service in NSSM successfully. But when I start the service I get error windows could not start the service on local computer the service did not return an error . What else can I do to tackle this problem? Trust me I have tried all solutions in stack overflow. I closed cmd when starting service. Gave all control to network service

How to do scheduling task in django and selenium combine project?

不羁的心 提交于 2021-02-11 14:34:13
问题 I am working on a web app project in Django with selenium where per one user there is one chrome browser open also chrome profile directory per user and chrome stay alive 24/7. Where the user can send msg or schedule msg. My problem is how can I send a schedule msg ? The following problem I am facing while working on my project: How to open a browser that already associated with my user because I already have user chrome profile directory per user and chrome is always open. I want that user

Powershell script scheduled task output to log file

血红的双手。 提交于 2021-02-11 13:56:33
问题 I have Powershell script with some Write-Host but I want to use it as scheduled task. I added it as scheduled task with this: $action = New-ScheduledTaskAction -Execute "$pshome\powershell.exe -WindowStyle Hidden" -Argument "-File $FilePath" $trigger = New-ScheduledTaskTrigger -Once -At (Get-Date).Date -RepetitionInterval $repeat Register-ScheduledTask -TaskName $Name -Trigger $trigger -RunLevel Highest -Action $action Can I make it write to log file? Is it possible to make it write to file

As a recipient, is it possible to detect if an email was sent via Gmail's “Schedule Send” vs. “Send”?

∥☆過路亽.° 提交于 2021-02-11 13:30:04
问题 Just curious if the email headers are marked by Gmail to denote if the email was scheduled vs sent right away. 来源: https://stackoverflow.com/questions/63714946/as-a-recipient-is-it-possible-to-detect-if-an-email-was-sent-via-gmails-sched

Running Macro from .bat with another Access db open

微笑、不失礼 提交于 2021-02-10 16:23:12
问题 I need to run a few Access macros automatically periodically throughout the day, I do this by scheduling a batch file to open the relevant Access db and run the macro. The problem that I am having is, if I am working on another Access database and therefore already have an instance of Access open, the batch file runs but only opens the database containing the macro that is supposed to run and stops. So the macro doesn't run. Has anyone else had this issue or know how to solve it? The batch