Convert Application From PPC to Desktop

  • Thread starter Thread starter a b
  • Start date Start date
A

a b

I hope this isn't one of those stupid questions everyone laughs at me
about :)

I have an application written in C#, .NET Compact Framework, for the
Pocket PC. I want to recompile it so it can run on my desktop
(actually, I'm going to target a Tablet PC in the future if there's a
difference, but I figured until I get that device, I'll try this to get
a feel for how the conversion works.)

I looked for that as a target, and not surprisingly didn't find one. So
I made a new application and copied my existing source code over but it
won't work because there are elements of the .resx files which appear
very specific to the CF.

Is there a common way of doing what I'm trying to do? I thought I had
seen that one of the cool things about using the CF is that it can be
compiled using the full Framework since it is a subset with little or no
changes.
 
Have you tried simply running your PPC program on the desktop? As long as
you aren't using any unmanaged code, all .NET, then it should run fine.
 
Assemblies that are compiled against the CF will run on a desktop machine
with the .Net Framework V 1.1 installed, assuming that you haven't used
anything CF specific in your code. This is because CF-compiled assemblies
become "retargetable". But there are differences, as you have noted within
the resx files. This can be a painful process to port from a device, lets
say a PPC, to the desktop. The biggest issue is related to the
display/screen information. IMO if you must do something along these lines
then you should plan for this from the start of the application dev process.
Wrap all your business logic in CF-compiled assemblies, obviously you are
now limited to the subset of managed CF calls. But in relation to your UI I
would say create two different presentation layers - one for the PPC, and
one for the desktop. You can reference your business components from both of
these projects and life *shouldn't* be too complicated from there...
 
*If* you're not using anything PPC-specific it doesn't even need a
recompile. A CE binary will just run on the desktop. However if you do use
PPC-specific stuff, then it obviously won't run on the desktop. In those
cases you need logic to determine the platform at runtime and branch to
logic depending on the result.
 
it's not 100% true !
some one recently run his program compiled against PPC on the Desktop and it
didn't work.

And Alex Feinam itself said:
"Some of the components in CF are packaged differently than on the desktop.
System.Web.Services is one of those"


--
ihookdb
Get your data mobile
http://www.ihookdb.com
Chris Tacke said:
*If* you're not using anything PPC-specific it doesn't even need a
recompile. A CE binary will just run on the desktop. However if you do use
PPC-specific stuff, then it obviously won't run on the desktop. In those
cases you need logic to determine the platform at runtime and branch to
logic depending on the result.
 
Back
Top