 |
BorlandTalk.com Borland discussion newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
Doug Stephens Guest
|
Posted: Fri Apr 21, 2006 8:03 pm Post subject: Giving users a new version of my program |
|
|
I am about to deploy a D7 app to about 20 users, LAN connected. On the
off chance that bugs are found, I am thinking about how to replace the
EXE with a new fixed version. The current approach has been to copy the
EXE to the local drive from a network location, then give the users a
BAT file which will copy a new EXE to the local drive. They run this
based on an email which tells them a new version is available. Of
course they often forget and continue to run the wrong version and we
get calls. So I'm seeking something more reliable.
I was considering having users run the EXE directly from network drive
via a shortcut. When I need to update the version, I would rename the
old EXE and copy the new one there. Then users would just have to exit
and restart the program from their shortcut.
I thought this would not be possible if people were still using the
EXE, which would render this approach pretty useless, but I just tested
it and to my surprise I was able to rename the EXE file even though
people were running it. Then I could even delete it and the running
instances still ran. This seems weird to me. I guess XP must load the
entire EXE at startup then never refers to the disk copy again. Speed
was almost identical except for initial load time, which is
understandable. Oddly, you cannot delete it without renaming it first
if it is in use.
Was I just lucky in my limited testing and sometimes the EXE would need
to re-read the disk copy? Any comments on this approach? Or other
suggestions?
Thanks
- Doug |
|
| Back to top |
|
 |
Doug Stephens Guest
|
Posted: Fri Apr 21, 2006 9:03 pm Post subject: Re: Giving users a new version of my program |
|
|
Doug Stephens wrote:
| Quote: | I am about to deploy a D7 app to about 20 users, LAN connected. On the
off chance that bugs are found, I am thinking about how to replace the
EXE with a new fixed version. The current approach has been to copy
the EXE to the local drive from a network location, then give the
users a BAT file which will copy a new EXE to the local drive. They
run this based on an email which tells them a new version is
available. Of course they often forget and continue to run the wrong
version and we get calls. So I'm seeking something more reliable.
I was considering having users run the EXE directly from network drive
via a shortcut. When I need to update the version, I would rename the
old EXE and copy the new one there. Then users would just have to exit
and restart the program from their shortcut.
I thought this would not be possible if people were still using the
EXE, which would render this approach pretty useless, but I just
tested it and to my surprise I was able to rename the EXE file even
though people were running it. Then I could even delete it and the
running instances still ran. This seems weird to me. I guess XP must
load the entire EXE at startup then never refers to the disk copy
again. Speed was almost identical except for initial load time, which
is understandable. Oddly, you cannot delete it without renaming it
first if it is in use.
Was I just lucky in my limited testing and sometimes the EXE would
need to re-read the disk copy? Any comments on this approach? Or other
suggestions?
Thanks
- Doug
|
Just saw Rick Anderson's post below. Sorry for the duplication.
Some good ideas there. |
|
| Back to top |
|
 |
Bill Todd Guest
|
Posted: Fri Apr 21, 2006 9:03 pm Post subject: Re: Giving users a new version of my program |
|
|
Doug Stephens wrote:
| Quote: | Was I just lucky in my limited testing and sometimes the EXE would
need to re-read the disk copy? Any comments on this approach? Or other
suggestions?
|
You were lucky. More often you cannot rename or delete the EXE when it
is in use. Never the less, this is still the easiest way to deploy. If
necessary create a batch file that copies the new EXE into place and
run it in the middle of the night with Windows Scheduler.
--
Bill Todd (TeamB) |
|
| Back to top |
|
 |
Mike Williams (TeamB) Guest
|
Posted: Fri Apr 21, 2006 9:03 pm Post subject: Re: Giving users a new version of my program |
|
|
Doug Stephens wrote:
| Quote: | Is it preferable to run off a network drive or local? I've always
thought that local was faster, but seems only so for initial load
time.
|
I think local is typically better.
One approach to this problem that I took years ago is to write a
"launcher" application. I called it "NetRun". The idea is to have a
configuration file that lists a network source directory, a local
directory, and the command line to run. This configuration file has an
extension that is associated with the launcher application such that
double-clicking the config file or launching it from a shortcut calls
the launcher application.
The launcher first looks to see if the local version does not exist or
is older than the network version. If so, it copies down the new files
and then executes the appropriate command line. If the local
executable is already the current version it simply runs it.
This approach gives you the ability to simply copy an update into place
on the shared drive. Users will get the new version the next time they
attempt to launch it.
--
-Mike (TeamB) |
|
| Back to top |
|
 |
Doug Stephens Guest
|
Posted: Fri Apr 21, 2006 9:03 pm Post subject: Re: Giving users a new version of my program |
|
|
Bill Todd wrote:
| Quote: | Doug Stephens wrote:
Was I just lucky in my limited testing and sometimes the EXE would
need to re-read the disk copy? Any comments on this approach? Or
other suggestions?
You were lucky. More often you cannot rename or delete the EXE when it
is in use. Never the less, this is still the easiest way to deploy. If
necessary create a batch file that copies the new EXE into place and
run it in the middle of the night with Windows Scheduler.
|
Is it preferable to run off a network drive or local? I've always
thought that local was faster, but seems only so for initial load time.
The exe is 8mb.
- Doug |
|
| Back to top |
|
 |
Bill Todd Guest
|
Posted: Fri Apr 21, 2006 11:03 pm Post subject: Re: Giving users a new version of my program |
|
|
Doug Stephens wrote:
| Quote: | Is it preferable to run off a network drive or local? I've always
thought that local was faster, but seems only so for initial load
time. The exe is 8mb.
|
It is up to you. I prefer running from a network drive because
maintenance and setup of new PCs is much easier. When someone gets a
new PC all they have to do is create a shortcut to the EXE on the
server and they are done.
--
Bill Todd (TeamB) |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|