本文介绍了在服务器或云上每天运行C#脚本,而不是本地运行的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述 我是自动化任务的初学者。我没有相关的经验。 我在C#中有2个脚本(和一个在CollabNetTeamForge的CLI中,但是现在我们可以忘记这个最后一个) 。 这些脚本生成两个在XML门户中连接和同步的 XML 文档。 我在我的PC上本地测试了这个架构流从 它的工作原理,但我想做的是自动化执行并修复此流程的远程存储 - 脚本的。我想修复一个任务,执行并保存这个脚本 in-from 一个外部路径(不在我的PC本地)为了在没有人为干预的情况下更新SharePoint中的信息( XML docs)。 我试图找到信息,但我仍然有点迷失。我不知道哪些平台或资源让我这样做。有人能指出我正确的方向吗? 是否可以在服务器内部使用任务计划程序来创建任务运行两个脚本并每天/每小时覆盖XML?独立于PC? 解决方案 只需创建Windows服务并在其中使用计时器 它将在您的云上运行或服务器并按照您指定的时间间隔,您的c#代码将在云或服务器上运行。 我几年前为我的一个项目做了这个,因为asp.net或Web服务无法做到这一点.. Hi, I'm a beginner in automation tasks. I don't have experience on it.I have 2 scripts in C# (and one in CLI of CollabNetTeamForge,but for now we can forget about this last one).These scripts generate two XML docs which are connected and synchronized in a SharePoint Portal.I tested this architecture-flow locally from-in my PC and it works but what I want to do is automatize the execution and fix a remote storage of this flow-scripts. I want to fix a "task" which execute and save hourly this scripts in-from a external path (not locally in my PC) in order to keep updated the info (XML docs) in SharePoint without human intervention.I tried to find info but I still a bit lost. I don't know what platforms or resources let me do this . Could someone point me in the right direction?Is it possible to use a Task Scheduler inside of a Server to create a task wich run both scripts and overwrite the XMLs daily/hourly? Independently of a PC? 解决方案 Simply create windows service and use timer in itit will run on ur cloud or server and at your specified interval your c# code will be run on cloud or server.I did this for one of my project a few years ago because asp.net or web services cant do this.. 这篇关于在服务器或云上每天运行C#脚本,而不是本地运行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!
09-09 06:00