Re: Wanna add update function to my software.
From: Lee (luv2program2000_at_yahoo.com)
Date: 10/27/04
- Next message: Lee: "Re: Firebird / InterBase Structure Updater"
- Previous message: Alvaro GP: "Re: Custom Package"
- In reply to: Lauchlan M: "Re: Wanna add update function to my software."
- Next in thread: Sunisoft: "Re: Wanna add update function to my software."
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: 26 Oct 2004 19:21:33 -0700
Lauchlan M wrote:
> > A very simple solution is to use a ini file on your site stating the
> > version of the files. When your program start or the user want to
> > check for a newer version all you have top do is to download the
> > ini file and check it against the file version you are using.
> >
> > It is simple but gets the job done and it is free :)
>
> That doesn't do the updates though. You then need to download the new
> version, stop the running version, rename the running version and the
> new version, do whatever other changes are necessary (eg database
> structure, registry items), then run the new version.
>
> It seems to me the ini file would just help keep track of the
> versioning.
>
> Or am I misunderstanding what you are suggesting?
Now, this is a good thread. I've been using my own updating version
for about a year, but it only updates the executable files, not
supporting files.
I actually do have a question for vendors of updating software at the
end of this.
OK, this is what I do now. In the main application, we have a routine
that grabs an ini file from an internet site. The first thing we check
is what we call a "minmum db version" which is stored in our firebird
database. If the current db version is lower than what is required, we
notify the user that db updates are necessary and if they indicate it
is ok to do so, we shell out to another program called db_updater and
shut down the main application.
The db_updater then pulls down a script that is structured like this:
<============ example ========================>
#11.2%
ALTER TABLE COMPANYINFO
ADD CLOSEOUTCLOCKOUT BLANKSMALLINT;
&UPDATE CompanyInfo SET CloseoutClockout = 0;
*End*
<============ example ========================>
We just load it into a TStringList and parse through it until we get to
a dbversion line number that is newer than what is at the client side
and then start loading subsequent lines it into two separate
TStringLists. slDML and slDDL. After everything is read in, we start
a transaction for the DDL and execute that script. If all goes well
and no rollback is necessary, we commit that transation, execute the
DML and commit that transaction. There is also an option to backup the
db before hand which saves the .gbk to a date/time named file.
Then the Main application is restarted and the update process resumed.
DB updates aren't that frequent so it doesn't prove to be that big of a
deal. When the updates for our exe's are brought down, they are
stuffed into blob fields in the db along with the current exe version
in a VarChar field. When workstations software is started, its done
though a "loader" program that connects to the database, checks the
version numbers that are there against the version number of the local
exe and if newer, pulls it out of the database, overwrites the existing
exe then starts the exe. If the "central" version is not newer than
the local exe, the local exe is just started.
Whew.. sorry about that. NOw, here is my question; do current vendors
provide any type of similar functionality or is there plans to do
something like this? We don't allow the workstations to access the
internet for a) obvious security reason and b) they are worker based
terminals for POS and do not need internet access. The solution for me
was to create this centralized scheme for grabbing updates off the net
and making them available for local computers.
Any vendors have plans for something like this or can your software be
augmented to provide the same type of methodology? I want to start
being able to update supporting files in addition to the exe's (dll's,
help files, etc) and will start looking around for something like this
in the near future.
OK, quite enough typing for me that doesn't include If...Then's :0)
-- Warm Regards, Lee
- Next message: Lee: "Re: Firebird / InterBase Structure Updater"
- Previous message: Alvaro GP: "Re: Custom Package"
- In reply to: Lauchlan M: "Re: Wanna add update function to my software."
- Next in thread: Sunisoft: "Re: Wanna add update function to my software."
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|