HZNM.COM
welcome to my space
X
Search:  
 HOME   How to write an auto updater for my C++ programs?
How to write an auto updater for my C++ programs?
Published by: anonym 2009-01-08
Welcome to:hznm.com

  • I have written a few basic programs in C++ and I would like to make them auto update over the internet or over my intranet (I have a website and an intranet).

    I can upload files to my intranet and website fine but the problem is, I do not know how to write the code for an auto updater. Could someone please explain to me how to write an auto updater or provide a link to a website which explains how to make one. Any source code you could provide would be very useful. It can be in any language as long as it works with my C++ programs!

    I am only just starting so please keep it simple! Thanks in advance.

    Richard

    P.S. I am using Windows Vista Home Premium and Visual Studio 2008 Professional Edition.


  • Can't keep it simple, this is an advance topic. I'll give the general overview of a method to accomplish this.

    Things you'll need to understand
    TCP/IP - C++ to communicate through sockets and ports
    HTTP - C++ you'll need to send http encoded commands via http, so knowing how to construct an http message will be needed.
    PHP - (web server side )This is required to accept your commands from the c++ program and return your update

    Additional things:
    You'll need to determine a method to tell if you program needs to be updated, either through filename or file version. ( If you don't know then none of this will work)

    //General overview
    A c++ program will create a connection to the web server and the web server will check to see if it should send the update file or not.
    The web server side will receive an http encoded message, it will parse the string and determine the type of request.

    c++ program side
    ---------------------------
    1) - construct a c++ program to create a socket connection on port 80 ( internet port )
    2) Construct your http header request to send to your php script
    3) Read the response and store it, then execute it. ( Note the current program this will update will need to be turned of so you'll have to take that into consideration

    web server side
    ----------------------
    1) Grab and interpret the message
    2) send file if the message is appropriate
    or
    send message that no update is needed.

    Hope this gives you an overview, It's impossible to show you code because there is no simple method for this, too many scenarios and variables to consider and I don't know how much you know of the topics mentioned.


  • Most likely, you need a client/server application. You program keep running as a client, and connect to a server side support program over TCP/IP. Every loop, you can send a request to server, or just read of a new update through Socket.

    Good luck,
    peng

    Running SiteMonitor update site status every minute at http://www.eptop.com:8080/SiteMonitor/Di...


  • Since you are using visual studio, you can use the deployment options to acheive this. The easiest way is to use the click once deployment method. Open the project, right click on the projects name in the solution explorer, Click on the publish tab in the window, then click the updates button and answer the questions. Now deploy the project and install it and it will check for updates in the location that you specified.





  • What's the right content management software for me?
    I want to store a character(char variable) in a String matrix?

    You are looking at:hznm.com's How to write an auto updater for my C++ programs?, click hznm.com to home
  • hip hop history
  • the crusader a search for the virtue inside an excerpt of an epic poem
  • new m3 with competition package
  • competencies for recruitment professionals measuring their efficiency and roi
  • a game for all seasons
  • is nbcs reality show meet mr mom out of touch with reality
  • candid photography
  • grandpas mantel clock 1959
  • ellis island part three from the baltic
  • dear minuteman guy
  • the porch 1960
  • modeling portfolio webites
  • how to create a multi artistic piece part ii
  •  
  • the big mouse 1959
  • the dad behind the doodlebops
  • creating an interactive resume
  • the death defying warehouse party life an interview by william of orange
  • asylum chapter two from the baltic
  • keep a digital photos diary
  • casino olympics
  • first kiss 1963
  • online in your face
  • from the baltic july 1916 lithuania
  • mobile leads the way
  • take your online poker game to the next level
  • fried green tomatoes recipe
  • top rap song
  •  Homepage | Add to favorites | Contact us | Exchange links | LOGIN | Site map | 
    Copyright© 2008 hznm.com        Site made:CFZ