Using same DLL based Data Layer for PocketPC and WinForms PC project

P

Paul Aspinall

Hi
I am designing a small app which I want to have versions available for
PocketPC, and for PC using WinForms.

In order to tier the app logically, I want to use the same Middle tier
(Business Layer / Data Access Layer) for the 2 apps, which will be
functionally the same, but have different presentation layers.

Is it possible to use the same Middle tier for both PocketPC and WinForm
projects?? Do I need to compile one of the .CS files against .NET, and
..NETCF?? or will the same DLL work on both platforms without the need to
compile twice against each platform?

Thanks


Paul
 
P

Paul Aspinall

Thanks for your reply to my post in the NG.

Should the same DLL run on both CF and full FW?

What needs to be done to tell VS that the DLL will be used on CF??

I have a DLL which works fine in a fullFW version. I have written a very
simple piece of code which calls the same DLL from PocketPC. However, I
constantly get the error:

"An unhandled exception of type 'System.MissingMethodException' occurred in
System.Windows.Forms.dll"

Which I believe is because it can't find the method. If I remove the call to
my own DLL the app runs fine on pocketPC

For this reason, I believe that my DLL is not being compiled or accessed
correctly by PocketPC.

Do you have any suggestions or ideas??

Thanks



Paul
 
D

Daniel Moth

You have to compile the project(s) for the CF i.e. Smart Device Projects

Then they are retargetable which means the same binaries will run on the
desktop. The second link I provided has more info.

Cheers
Daniel
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top