Wednesday, March 21, 2012

Referencing to System.Data.SqlServerCe causes large files to deploy to Emulator

Hello everyone,

This is my first time posting here, I hope this questions has not been asked before. I tried to search for it but I came not with nothing.

Recreating the error :

I am using VS2005. I created a Pocket PC 2003 project.
I have downloaded the SQL Server Compact Edition and installed it. I get the System.Data.SqlServerCe.dll file from the installation directory.
I reference to that DLL using Add Reference in VS2005.

Build it. In the Bin folder, a long list of files suddenly appears.

System.data.dll

System.data.oracleClient.dll

system.web.dll

system.enterpriseservices.dll

system.enterpriseservices.wrapper.dll

system.transactions.dll

and the rest of your original files in Bin

The worst of it all, all of these files are deployed into the Emulator! Causing it to run out of memory and unable to deploy.

Something is not right here, I just cannot figure it out! If this happens, each mobile devices can hold one applications. Thats not the way it should be, right?

If you have solved this before, do help. I am at my wits end at the moment.

Thanking you in advance.

Sincerely,
Lasker

That means you have a reference to some desktop DLL(s) which brings pretty much entire desktop framework with it. It might be desktop version of System.Data.SqlServerCe.dll or it might be any other desktop DLL you’re referencing. You’d need to remove that reference and replace it with device one.

No comments:

Post a Comment