Re: My own autoupdater - problem

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



Thanks for the advice, it helped me discoverer that the trouble was very
likely not located in the area I thought it was.
The reason why the app wouldn't release its lock on its main executable, is
because the downloading process opened a few threads that I didn't know
about, and where kept alive without my knowledge. I figure the application
never exited, because it could not end the threads.

"Carmine Moleti" <carmineaskme@xxxxxxxxx> schreef in bericht
news:efg01s$ghq$1@xxxxxxxxxxxxxxxxxxxxxxx
I have created an autoupdater webservice for my PPC2003 application, and
have managed to retrieve the download.cab from my web service on my
device. Next, however, while trying to install the new version, I run
into the fundamental problem of not being able to run the installer cab,
since the old version of the application (which has spawned the
autoupdate request) is still running. When wceload then tries to install
the cab, it rightfully complains of a lock on the application executable,
not being able to overwrite the currently runnning version.

Of course the simplest workaround would be to let the user run the
update.cab file after closing the application, but there is no guarantee
my user base will be tech-savy enough to perform the necessary actions
(that is, a) open an explorer and b) let wceload.exe execute the cab-file
by clicking on it). I can think of some other options (create a process
which kills the current user application), but they don't seem elegant,
requiring much works for something that is or seems to be so simple.

Hi,

I'm still newbie on .Net but, from what I know, I think you should split
the autoupdate and the core app in two different appdomains.

I mean, having the main appdomain which checks for updates, download them
and install them.
More, this main appdomain takes care of launching the real application in
a separate appdomain.
This way should allow you to unload the real app and do the update.
Of course, it could happen that you'll need to also update the main
application (the one that implements the autoupdate feature). But I guess
it'll happens less frequently.

HTH,
Carmine


.



Relevant Pages

  • Re: My own autoupdater - problem
    ... Next, however, while trying to install the new version, I run into the fundamental problem of not being able to run the installer cab, since the old version of the application (which has spawned the autoupdate request) is still running. ... this main appdomain takes care of launching the real application in a separate appdomain. ... This way should allow you to unload the real app and do the update. ...
    (microsoft.public.dotnet.framework.compactframework)
  • Re: system drive change?
    ... and do a new install having sorted out the hardware. ... Enquire, plan and execute ... and I may have to uninstall and reinstall the thing tomorrow. ... What McAfee product was or is installed? ...
    (microsoft.public.windowsxp.perform_maintain)
  • Re: Trojan Horse
    ... NewCrapNet is not classified as a virus, ... > Download and install Ad-aware SE ... > signature files and install them before performing the scan. ... > Execute; CLEAN.EXE ...
    (microsoft.public.windowsupdate)
  • Re: Can you help me on and error message
    ... Execute the downloaded file and install it. ... >> you have to reinstall your app or download the next app and install it: ... >>> to know what the error message means, and is it my opertation system ...
    (microsoft.public.vb.general.discussion)
  • Re: Installation failure: Office (or Word) 2008 for Mac 12.0.1 Update - Why, now what?
    ... And yes, the Office AutoUpdate ... as the first thing in the install process, but failed at that point to do so. ... called "Microsoft AutoUpdate for Mac 2.1.1 Update," so I clicked on it to get ... I figured I probably should download this first, ...
    (microsoft.public.mac.office.word)