Source language: Translate to:

Auto-update your program

NeoBook tips, tricks, code samples and more...

Moderator: Neosoft Support

Auto-update your program

Postby Jim Brammer » Thu Feb 07, 2002 3:50 pm

is it possible to update a neobook application e.g screensaver with fresh content with a plugin or something else?

I want to sell screensavers that are weekle updated with new content.

anybody who knows a possibility which not costs $895.- like this one: www.indigorose.com/trueupdate/index.html

<hr>

As discussed a few times, it is quite possible to make your program automatically update itself over the Internet. By using a PlugIn that does FTP, or preferrably HTTP file transfers, you can create a program that checks for later versions of itself.

Versions would be indicated like this...
10 = version 1.0
11 = version 1.1

Your program should carry a version value (i.e., "10") by some method, either in an external text file, hardcoded in your program (if the program itself is the file that will be replaced), or written to the registry. The method you use will depend on what your program does and what elements of it are likely to be updated.

In a directory on your website you would place a text file that contains the latest version number, (i.e., "11"). Also on the website would be the lastest version update file.

Use the PlugIn to download this version text file. Next, use FileRead to read the value inside the file. If the downloaded version value is greater than the current version then again, use the PlugIn to download the update file from the website.

Last but not least your updated program should use some means of writing the new version number on the users system if it is not already hardcoded in the EXE itself.

I personally have done this and went a step further by making the whole process automated. User prompts along the way gave the user the option to abort at any time. The version was checked, downloaded, installed, and finally the new program was launched at completion. The Add-On that I made for the download returned "True or False" to indicate whether the download was successful or not. If "True" then I launched the self-extracting setup file and Exited the program immediately afterwards. The setup program had a user prompt, ("This program will install the update for..." etc.), and provided enough time for the running program to exit/unload. The last task performed by the setup program was to launch the users updated application.

<hr>

Update:

A later release of NeoBook 4 includes a command called BrowserExport that will allow you to download a text-based file from a webserver without the need for a Plug-In.
Jim Brammer
 

Return to NeoBook Knowledgebase

Who is online

Users browsing this forum: No registered users and 1 guest