python文件(.py)的任​​务计划 [英] task schedular for python file (.py)

查看:46
本文介绍了python文件(.py)的任​​务计划的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试在任务计划程序中安排任务我创建了一个批处理文件,如下所示

I am trying to schedule a task in task scheduler I have created a batch file as below

"C:\ProgramData\Anaconda3\python.exe" 
 "C:\helloo\mail.py" 
 pause

以上是我的批处理文件的内容.当我运行批处理文件时,我能够获得输出.我正在执行的代码没有遇到任何问题.但是使用任务调度程序,我遵循以下步骤

the above is the content of my batch file. When I run the batch file I am able to get the output. I am not facing any issue with the code which I am executing. But with task scheduler I am following the below steps

1.open task scheduler 
 2.create task -- provided the name of the task and description 
clicked on run whether the user is logged in or not and run with highest privileges 
3.in triggers -->new --> onetime --ok 
 4.Action --> new--> action :start a program -- 
program script: where I kept my batch file.
5.cliked on finish 
6. I am able to find the task in task scheduler but it is not showing as running 

我需要操作"选项卡中的帮助

I need assistance in Actions tab

推荐答案

我已经添加了如下操作选项卡

I have added the Action tab as below

1.in program i have mentioned PowerShell.exe
2. in next space i have mentioned -f " the file which you want to execute click on the file and click shift+right click and select copy as path " 

这篇关于python文件(.py)的任​​务计划的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆