如何更新“更新程序"? (C#) [英] How to update the "updater"? (C#)
问题描述
我有一个包含两个程序的程序:Updater和WorkMaker. 每当有适用于WorkMaker的更新时-Updater会将其杀死,下载更新,然后再次运行. 但是说我想出了新的Updater程序. 我该如何更新?通过WorkMaker?通过第三个程序? 谢谢.
I have a program that consists of two programs: Updater and WorkMaker. Whenever there is an update for WorkMaker - Updater kills it, downloads updates, and runs it again. But say I came up with new Updater program. How do I update it? Through WorkMaker? Through the third program? Thanks.
推荐答案
最简单的恕我直言的解决方案是:
The simplest solution IMHO is:
-
目前,在启动
Updater
之后,请求更新MainProgram
下载Updater
以及更新.
At the moment was requested update
MainProgram
downloadsUpdater
, along with updates, after launchesUpdater
.
更新程序将关闭MainProgram
,进行更新并重新启动MainProgram
,或直接退出.
Updater closes MainProgram
, makes update and relaunch MainProgram
, or simply exit.
通过这种方式,您可以灵活地更新程序(MainProgram
),也可以在需要时更新Updater
本身.
In this way you have flexible way to update your program (MainProgram
), but also Updater
itself, when its required.
希望这会有所帮助.
这篇关于如何更新“更新程序"? (C#)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!