Automatically update program source code download (C #. Net)

Source: Internet
Author: User
The update program provided by Microsoft is not easy to use, so I wrote this program again. The upgrade file and the configuration file updatelist. XML are used to update and upgrade the local program file through the version numbers of the local program and the server program file.
The updatelist. xml file contains the following content:

<? XML version = "1.0" encoding = "gb2312"?>
<Autoupdater>
<Description> application AutoUpdate </description>
<Updater>
<URL> http: // 10.0.5.98/softupdate/</URL>
<Lastupdatetime> 2005-09-05 </lastupdatetime>
</Updater>
<Application applicationid = "itemsoft">
<Entrypoint> itemsoft.exe </entrypoint>
<Location>. </location>
<Version> 1.0.0.0 </version>
</Application>
<Files>
<File ver = "1.0.0.0" name = "itemsoft.exe"/>
<File ver = "1.0.0.0" name = "reports \ test.txt"/>
<File ver = "1.0.0.0" name = "InterOP. grprolib. dll"/>
<File ver = "1.0.0.0" name = "reports \ test. GRF"/>
</Files>
</Autoupdater>

Note:
<Description> </description> description of the program;
<URL> </URL> Update the server address to a virtual directory or site path;
<Entrypoint> </entrypoint> Update the main program file, which is exe;
<Location>. </location> Update the path of the main program file;
<Version> 1.0.0.0 </version> main program version;
<Files> </Files> list of files to be updated; Ver: file version number, name: file name, including path (relative );

In use, create a web virtual directory or site on the Update Server, and then put the file to be updated and updatelist. xml on it;
Put autoupdate.exe and updatelist. XML in the root directory of the main program. If the version number of the local updatelist. xml file is smaller than that of the server, the automatic program automatically downloads the file to be updated.
The update program is used in the project included in my complete. Net Package download.
Download source code:/files/Jenry/autoupdate.rar
Download binary files:/files/Jenry/bin.rar
Generate the configuration file updatelist. xml tool:/files/Jenry/aulwriter1.0.rar (provided by whatisgood, thank you !!) New

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.