Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Auto Patcher / Updater

Status
Not open for further replies.

ICTECH

Technical User
Joined
Jun 5, 2002
Messages
131
Location
CA
Hi All..

I'm trying to figure out a way to have my application auto update itself. I found a couple of web sites, but they are all for VB.NET 2003. I'm still using 2002. What I was thinking was to use a WEB site to hold the updated files and have the usdater check the web site to see if there is a new version available, if yes, download and install it. If not load the current application. This is similair to the what some online games work. Thank you all for any help you can give..

 
Hi Christiaan,

Thanks for the web site. Will check it out...



 
Hi Christiaan,

I tried out the code. But I keep getting "The path is not of a legal form". Were you able to get it working??



 
no i didnt try it. I use my own system but is locally on our network and it uses sqlserver. I put a textbox on my mainscreen with the currentversion then i made a table with one field (the versionnumber) if both are equal do nothing else run setup)

Code:
reaTemp = Docmd.FillDataReader("SELECT versionnumber FROM dbo.[tbl_versionnumber]", Docmd.Databases.General)
        reaTemp.Read()
        strTemp = reaTemp.GetValue(0)
        reaTemp.Close()
        If TxtVersion.Text.Trim <> strTemp.Trim And strTemp.Length > 0 Then
            Timer1.Enabled = False
            if MessageBox.Show("There is a newer version available, do you want to install it now? All open databases will be closed automatically. Don't forget to save!", "", MessageBoxButtons.YesNo, MessageBoxIcon.Question) = 6 then
                Dim proTemp As New System.Diagnostics.Process
                proTemp.StartInfo.FileName = "s:\setup.exe"
                proTemp.Start()
                proTemp.WaitForExit(100000)
                proTemp.StartInfo.FileName = Application.StartupPath & "\tex databases.exe"
                proTemp.Start()
                Me.Close()
            End If

Christiaan Baes
Belgium

What a wonderfull world - Louis armstrong
 
Hi,

Anyone know how to query the actual EXE version number? What I'd like to do is create an App start wrapper that checks the local application EXE with one placed on a network drive.

Thus when I have a new release I copy the relase folder to the shared network drive and alongside the Setup.exe I would place the new application exe.

Wrapper pgm would then check the local exe against the network exe and if different then it would call the SETUP.EXE and end else it would load the local app.

W.

Bill Paton


Check out
 
Good suggestions, but your are trying to invent something that is built in .NET.
Did you hear about zerolevel deployment? The idea is that you hold all files needed to run you application in a folder shared on the internet using IIS. All users need to do is to open this link:
The .NET framework do all the work for you. If this is the first time this user doing it, it will download your exe and all dll it references. If not, it will only check the version of those files.
However, You need to make a security change in the user machine, dependes on what your application is doing. These changes can be done through "Microsoft .NET Framework 1.1 Configuration" in "Administrative tools". You can make an MSI file that each user need to run before he open your application for the first time, and this will change his securtiy settings.
More information:
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top