Results 1 to 13 of 13

Thread: AKLib.SimpleUpdater

Threaded View

  1. #1

    Thread Starter
    Fanatic Member Arve K.'s Avatar
    Join Date
    Sep 2008
    Location
    Kyrksæterøra, Norway
    Posts
    518

    AKLib.SimpleUpdater

    AKLib.SimpleUpdater
    A simple way to let your application install updates

    Written in Visual Studio 2010

    Edit: Changed the attachments to Zip


    Instructions:
    1. Download, extract and build the two attachments
      .
    2. Add a reference to AKLib from your designer
      .
    3. Copy SimpleUpdater.exe to your applications directory
      .
    4. Create a file called 'current.txt'

      • Layout of the file should be like this:
        Legend: The file that you want to update,current version,the folder where you want to download the update

        myApplication.exe,1.0.0.0,C:\MyApplication
        myDll.dll,1.0.0.0,C:\MyApplication
        etc...

      • Copy 'current.txt' to your applications directory

      .
    5. Create a file called 'recent.txt'
      • Layout of the file should be like this:
        Legend: File on update server,newest version,the url to the file

        myApplication.exe,2.0.0.0,http://www.myserver.com/updates/myApplication.upd
        myDll.dll,1.1.0.0,http://www.myserver.com/updates/myDll.upd
        etc...

      • Upload 'recent.txt' to your site

      .
    6. Usage:
      • From a Button.Click event:
        vb Code:
        1. Private Sub btnUpdate_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnUpdate.Click
        2.     Me.btnUpdate.Enabled = False
        3.  
        4.     Dim currentVersions As String = "C:\MyApplication\current.txt"
        5.     Dim recentVersions As String = "http://www.mySite.com/recent.txt"
        6.     Dim pathSimpleUpdater As String = "C:\MyApplication\SimpleUpdater.exe"
        7.  
        8.     AKLib.SimpleUpdater.FromDefinedList(currentVersions, recentVersions, pathSimpleUpdater)
        9.  
        10. End Sub

      • Ta-da

      .
    7. Credits to:

      .
    8. Disclaimer: There is basicly no error handling in this code, and I have only tested it on one computer, so is to be used at your own risk
    Attached Images Attached Images  
    Attached Files Attached Files
    Last edited by Arve K.; Aug 3rd, 2010 at 07:29 AM. Reason: Added zip instead of rar
    Arve K.

    Please mark your thread as resolved and add reputation to those who helped you solve your problem
    Disclaimer: I am not a professional programmer

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width