Thursday, June 21, 2007

Installing .CAB files on a Device with the Command-Line Tools or the ActiveX control

With the Srego CE Toolpack Command lines tools, there are two way to install a cab file on the device:

1) The cePush command has a /deploy flag. If this flag is specified and you are pushing a .cab file to the device, it will automatically be installed after it is copied to the device.

cePush sample.cab /deploy

2) the ceStart utility can also be used. If the .cab file is already on the device, you can specify something like this to activate the .cab file on the device:

ceStart \windows\wceload.exe "\my documents\sample.cab"


If you are using the Srego CE Toolpack ActiveX control, you will use the StartApplicationEx method as shown below with VB6 sample code:


Dim stat As Boolean

Dim parameters As String

parameters = Chr(34) + "\my documents\PGTViewer_WinMobile_7004.CAB" + Chr(34)

stat = SregoCETPx1.StartApplicationEx("\windows\wceload.exe", parameters)

There are two keys to making the StartApplicationEx correctly activate the .cab file. The application parameter must be “\windows\wceload.exe” and the parameters must be the path to the .cab file. If the path has spaces in it, you must put quotes around the path as shown in this example.

1 comment:

Anonymous said...

Nice post you got here. I'd like to read more concerning that matter. The only thing your blog needs is some photos of some devices.
Kate Watcerson
Phone jammers