Special

Introducing the “Welcome to Xojo” Bundle!

New to Xojo and looking for guidance? We've put together a terrific bundle to welcome you! Xojo Bundle

This bundle includes six back issues of the magazine -- all of year 21 in printed book and digital formats -- plus a one-year subscription (beginning with 22.1) so you'll be learning all about Xojo for the next year. It's the perfect way to get started programming with Xojo. And you save as much as $35 over the non-bundle price!

This offer is only available for a limited time as supplies are limited, so hurry today and order this special bundle before the offer goes away!

Article Preview


Buy Now

Issue 9.2

COLUMN

Updating Self-Updater

Using HTTPSocket to download a file

Issue: 9.2 (January/February 2011)
Author: Marc Zeedar
Author Bio: Marc taught himself programming in high school when he bought his first computer but had no money for software. He's had fun learning ever since.
Article Description: No description available.
Article Length (in bytes): 9,926
Starting Page Number: 71
Article Number: 9210
Resource File(s):

Download Icon 9210project.zip Updated: 2013-03-11 19:08:01

Related Web Link(s):

http://www.rbdeveloper.com/downloads/appos9.sit<
http://www.rbdeveloper.com/downloads/apposx.zip<
http://www.rbdeveloper.com/downloads/appwin.zip<

Excerpt of article text...

A few years ago I wrote a simple application updater (see "Update Yourself" in RBD 3.3) that allows your app to check with your website to see if there's a new version of the app available. The code still works but is a little dated, so I thought I'd update it.

Though not the most powerful, my self-updater is simple, and one of the nice things about it is that all the code fits into a single window object you can drag into any REAL Studio project (there are no dependencies on other objects or classes).

One drawback, however, is that it has traditionally simply passed the application download process to the user's default web browser. Since that download process can happen in the background, this can confuse users who aren't aware that something is happening. I've had reports of my users downloading a file multiple times because they didn't realize it had already downloaded. To fix this, I decided to modify my code to download the file directly.

By the way, if you aren't familiar with my original article, either go to the back issue and read up on it, or read my quick summary in the "Self-Updater Refresher" sidebar within this article. You may find it will help you follow things better.

Updating the Project for 2010

Because my original project was written in a much earlier version of REALbasic, we first need to update the project for the current version of REAL Studio.

...End of Excerpt. Please purchase the magazine to read the full article.