CF application, with source, recompiled for .NET

  • Thread starter Thread starter Keven Corazza
  • Start date Start date
K

Keven Corazza

Hi,

I would like to be sure if there are some possibilities to take the source
code of a CF application and recompile to create a .NET application.

I've to say that the application uses OpenNETCF library and call O.S.
library thorugh P-Invoke.

Which problems I've to face ?
Have I to recompile OpenNETCF library ? Is it possible ?

Thank you for your help.

Regards

Keven Corazza
 
As with any set of code that depends on a library, this might or might not
work, depending on what features of the .NET CF 'library' you are actually
using. If you have a simple Windows Forms application, yes, it will more or
less just work. If you are doing things with the WindowsMobile namespace,
none of that will work.

Most of the managed-only portions of OpenNETCF should be retargetable
(ApplicationEx), I think. Anything that OpenNETCF P/Invokes will have to be
changed, as the DLL names on desktop Windows are all different than on
Windows CE, so the DllImport attributes will all be wrong.

Generally, if I have to do this sort of thing, I throw away the user
interface for Windows CE and build a new one for the desktop. The business
logic code should port fine and much of what OpenNETCF does was put there to
fill in missing pieces of the .NET Framework that .NET CF didn't have, so you
can just use the real framework on the desktop for those things. The rest
you'll have to port by hand.

Paul T.
 
Thank you for the detailed answer.


Paul G. Tobey said:
As with any set of code that depends on a library, this might or might not
work, depending on what features of the .NET CF 'library' you are actually
using. If you have a simple Windows Forms application, yes, it will more or
less just work. If you are doing things with the WindowsMobile namespace,
none of that will work.

Most of the managed-only portions of OpenNETCF should be retargetable
(ApplicationEx), I think. Anything that OpenNETCF P/Invokes will have to be
changed, as the DLL names on desktop Windows are all different than on
Windows CE, so the DllImport attributes will all be wrong.

Generally, if I have to do this sort of thing, I throw away the user
interface for Windows CE and build a new one for the desktop. The business
logic code should port fine and much of what OpenNETCF does was put there to
fill in missing pieces of the .NET Framework that .NET CF didn't have, so you
can just use the real framework on the desktop for those things. The rest
you'll have to port by hand.

Paul T.
 
Back
Top