The .NET Compact Framework is a subset of the full .NET Framework with some additional features for developing mobile devices. If you want to compile a library for Windows and Windows Phone, you need to create your own code for each platform.
You can still use most of the same code that you used for your .NET library, but you will need to use preprocessor symbols and conditional compilation to eliminate functionality for the desktop (or phone) that is not supported in another environment.
To do this: create two projects. One project will contain all your files designed for the desktop framework. Another will contain linked versions of your files for a compact structure. You can define characters in each project to run conditionally compiled blocks of code.
This means that any investment you have already made in .NET will be easily transferred to the Windows Phone world, but you must also be sure that the performance characteristics of your library will be easily supported by a less powerful device.
Good luck
Ed altorfer
source share