Question

I made an application that I put onto the hard disk of Win CE (the Compact Flash card). My problem is that the application is using the SQL Server CE 3.5 database but it looks like that the image is created with the SQL Server CE 3.0. I couldn't select the 3.5 version when I started to build the image.

The 3.5 version dlls are deployed every time I debug the application so the problem never shows up in the development phase.

Now when the application starts (it is started automatically when OS boots) the message window with exceptions pops up and don't let the application to start. My question is how to install the SQL Server CE 3.5 into the image or how to install it using CAB files later or on every boot up time.

When I run the correct CAB files (three CAB) on running OS system it installs the 3.5 version and my application starts but when I reboot the OS again the changes are not saved and commit. There must be a solution to add the 3.5 version in the catalog before building the image or to install it on every boot up time or the last option to install it permanently once after the first boot.

If you can provide me the solution to install the CABs every time the system boots up It will work for me but then take into the consideration that I have to run the application that will use the SQL Server CE 3.5 database on system start so the installation of the CABs must precede the application autostart.

Thanks in advance.

Was it helpful?

Solution

You have a few options. The least desirable is to run the CAB at startup.

One option is to put the newest SQLCE binaries into the OS if you can. This is available in the catalog, provided you have all of the updated QFEs installed. If, for whatever reason, you can't install the QFEs, you could always replace the source binaries Platfrom Builder pulls from at %WINCEROOT%\OTHERS\SQLCOMPACT.

Another option is to just include all of the SQLCE binaries in your application deployment. You don't need a CAB, just put the DLLs in your app folder (removing SQLCE from the OS is a good idea if you go this route to prevent native DLL collision). The source for these binaries is at %PROGRAM_FILES%\Microsoft SQL Server Compact Edition\v3.5\Devices. This is actually the route I prefer, as an update to SQLCE doesn't require a new OS.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top