Click here to Skip to main content
15,891,033 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
Hi everyone! It is possible to have a Windows Forms application check for updates to the files if the updates are stored on a server and if so, automatically synchronize with the updates by downloading the newest versions? If so, is this a recommended method to deploy updates or should it be conventional of just deploying updates via InstallShield Deployments?
Posted
Comments
Sergey Alexandrovich Kryukov 6-Nov-12 13:41pm    
Are you doing this for deployment of detecting of deployments from a client side? These are two opposite things. Describe the scenario. Do you mean that this is the deployment of software to be installed/upgraded on the client side?
--SA
joshrduncan2012 6-Nov-12 13:45pm    
Hopefully I can clarify what I'm referring to.

First of all, the major upgrade is deployed and installed (Version 1.0, 2.0, 3.0, etc).
Second of all, we want to be able to send the .sdf files (or updates to .dll files) to a server for the windows application to detect it via synchronization.
Next, if the application finds updates, it downloads it automatically to that install location.
Finally, the application will detect the updates and use them accordingly without the client knowing what was downloaded and updated.

I hope this makes sense.

1 solution

Of course this is possible, but you should understand that the Web is pure client-server, so it won't give you any notification unless you program the deployment process this way, only if you can access the programming of this process. That said, if you want to download newer versions from the site you are not supporting, you will need to poll data from time to time. To do it, you can use the class System.Net.HttpWebRequest and get the news in System.Net.HttpWebResponse:
http://msdn.microsoft.com/en-us/library/system.net.httpwebrequest.aspx[^],
http://msdn.microsoft.com/en-us/library/system.net.webresponse.aspx[^].

Please see my past answers:
How to get the data from another site[^],
get specific data from web page[^].

See also: http://en.wikipedia.org/wiki/Web_scraping[^].

If the Web development on the site used for deployment is accessible to you, you can do a bit better and develop some subscription-based system (see also http://en.wikipedia.org/wiki/Publish%E2%80%93subscribe_pattern[^]).

The most natural way of doing this in a Web application would be implementing of the user membership system and authentication. The user account data can store the recent status of the user's updates and track it. When a user is authenticated, you can compare this data with latest software status and inform the user: "nothing new" or "{0} updates are available", something like that. On the client side, the client code can automatically check it up, using the approach I described above.

—SA
 
Share this answer
 
v3
Comments
joshrduncan2012 6-Nov-12 13:53pm    
Thanks Sergey!
Sergey Alexandrovich Kryukov 6-Nov-12 13:56pm    
My pleasure.
Good luck, call again.
--SA

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900