.NET デスクトップ アプリケーションと .NET CF アプリの間で特定のデータ機能を共有したいと考えています。
両方のバージョンのアプリケーションからアクセスできるユニバーサル ライブラリを作成することはできますか? それとも 2 つの個別の DLL を作成する必要がありますか?
.NET デスクトップ アプリケーションと .NET CF アプリの間で特定のデータ機能を共有したいと考えています。
両方のバージョンのアプリケーションからアクセスできるユニバーサル ライブラリを作成することはできますか? それとも 2 つの個別の DLL を作成する必要がありますか?
Yes--the desktop .NET runtime knows how to load and run .NET CF DLLs, so your first step would be to build your library for the Compact Framework.
You'll find that from time to time you'll want to use features of the Desktop framework, and you can pull those in using reflection.
Here's a very through intro to the process in MSDN Magazine.
NOTE: If it's possible for your mobile and desktop versions to share code but not the .dll specifically, then you'll have an easier time building this and staying happy if you use conditional compilation instead.