简体   繁体   English

Windows 7使用C#TaskScheduler库创建的.job文件是否过时?

[英]Are the .job files created using the C# TaskScheduler library obsolete for Windows 7?

I am using this library http://www.codeproject.com/KB/cs/tsnewlib.aspx to try and schedule tasks for Windows 7. When I create a task the file extension it is saving it as is .job which I think was fine for scheduling tasks in Windows XP. 我正在使用此库http://www.codeproject.com/KB/cs/tsnewlib.aspx尝试为Windows 7计划任务。当我创建任务文件扩展名时,它将文件保存为.job,我认为非常适合在Windows XP中计划任务。 For Windows 7 it is not recognizing the .job file extension and is looking solely for a .xml file. 对于Windows 7,它无法识别.job文件扩展名,而只是在寻找.xml文件。

Is this library obsolete for Windows 7 or am I missing something altogether? 对于Windows 7,该库是否已过时?或者我完全缺少某些库? Is there a way to tie the .job files into Windows 7? 有没有办法将.job文件绑定到Windows 7?

Thanks in advance. 提前致谢。

Task Scheduler 1.0 was used in Windows 2000/XP/Server 2003. However, the differences in the file types and content are a result of Microsoft changing the way Windows handles tasks with Task Scheduler 2.0, which is used in Vista, 7, and Server 2008. With 2.0, came the switch to XML-based files and a few more features. Windows 2000 / XP / Server 2003中使用了Task Scheduler 1.0。但是,文件类型和内容的不同是Microsoft更改了Windows使用Vista,7和Server中使用的Task Scheduler 2.0处理任务的方式的结果。 2008年。随着2.0的发布,人们开始转向基于XML的文件和其他一些功能。

Perhaps you should try adding the Task Scheduler 2.0 API to your project and using that. 也许您应该尝试将Task Scheduler 2.0 API添加到您的项目中并使用它。

This is an article I found: http://community.bartdesmet.net/blogs/bart/archive/2008/02/23/calling-the-task-scheduler-in-windows-vista-and-windows-server-2008-from-managed-code.aspx 我发现这是一篇文章: http : //community.bartdesmet.net/blogs/bart/archive/2008/02/23/calling-the-task-scheduler-in-windows-vista-and-windows-server-2008 -从管理,code.aspx

HTH. HTH。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM