How to update my application
Question posted by: Lokutus
(Newbie)
on
August 20th, 2008 09:38 PM
Hi,
I'm developping an application for mobile device, windows mobile 5.0, using .NET Compact framework 2.0.
I need to update my application after it starts. Application will download a new CAB file from server if there is any and install it to update application.
Is there some easy and common way to accomplish that, or do I have to run some updater, close the application and install a new version using that updater?
And another question. Is there a way to install CAB file at the background not visible to user? I need to do update uninteruptable.
Thanks in advance, Lokutus
2
Answers Posted
Moving to Mobile Dev forum.
Yikes! That's a toughy.
One way I like to do this kind of thing is with a web service exposed on the server, use your app to connect to the service using it's connection, download something like a byte[] for you cab file and then using
-
// Open Cab File
-
ProcessStartInfo myCab = new ProcessStartInfo();
-
myCab.FileName = "\\Temp\\myCab.CAB";
-
myCab.StartInfo.Verb = "Open";
-
myCab.UseShellExecute = true;
-
Process.Start(myCab);
-
Cursor.Current = Cursors.Default;
But you may find that you can not run that while the application is running. I would probably create another application to do this, and launch it from you current app, then in your updater check to see if the original app is running, and if so close it.
That is all in theory though, I have never run a CAB updater from local software before, I tend to use 3rd party software.
Hope it points you in the right direction
Mark
|
|
|
What is Bytes?
We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights.
Get the best answers to your questions from over 197,043 network members.
Top Mobile Development Contributors
|