I recently upgraded a VS2005 solution for a WinMobile5 app to VS2008. The solution also contains a CAB builder project plus an MSI Desktop Installer project. A custom DLL from the installer takes care of deploying the app plus supporting CABs, like Compact Framework 2.0, scanner libraries, etc to the actual device.
I used this article as a guide for MSI installation:
http://msdn.microsoft.com/en-us/library/aa446504.aspx
Problem is, the CF2 CAB won't install successfully to a WM5 device from Win7 when running the Setup.exe / MSI file. However, installing from XP works fine.
Summary:
-Windows7 32-bit machine - VS2008 / WM6 SDK (includes WM5 support)
-Symbol WM5 Device - MC70
-Windows Mobile Device Center
-Created Desktop MSI to install CF2 CAB plus my app's CAB thru Custom DLL
-During install (running as admin) my app's CAB install successfully, the CF2 CAB says "Installation was unsuccessful"
-However running/debugging the app from VS2008 will deploy CF2 correctly, so it CAN work.
Interesting tidbit:
I pulled back the funky CF2 CAB from the device to compare with source, located here:
C:\Program Files\Microsoft.NET\SDK\CompactFramework\v2.0\WindowsCE\wce500\armv4i\NETCFv2.wm.armv4i.cab
To my surprise, the device CAB had two HEX bytes different than the source. From beginning:
4D 53 43 46 00 00 00 00 68 48 (from Pullback) rest is same
4D 53 43 46 00 00 00 00 50 22 (from Source) rest is same
When I replace the "68 48" CAB with the "50 22" CAB and launch manually on the device, it installs nicely. So my question, is: Why is the source cab slightly altered once it reaches the destination device? Other than that, the files are identical.
Other things I've tried:
From scratch creating a small App targeting WM5/CF2. Adding a CAB project, adding a Setup & Deploy project. Run Setup from XP, great! Run Setup from Win7, BOOM!
/Device root does not contain a CF2 Install Log. Doesn't get that far.
VOLATILE/Setup.log contains no "error".
I've also tried the UberCab approach (bundling multiple CABs into one CAB). However, when unbundling on the device: BOOM fail. It somehow knows.
I'm at my wit's end. The CF2 piece should just work.
-Tom