Converting a Windows CE .NET CF application to run on std Windows?


A

Alain Dekker

I have an application which runs nicely on Windows CE 5 (uses .NET CF 2.0).
Our sales and service teams would like a demo version of this application to
run on their laptops running Windows XP / 7. Is there a (relatively)
straightforward way to take the latest source of the Windows CE app and
compile a Windows NT version? Using Visual Studio 2005.

Thanks in advance,
Alain
 
Ad

Advertisements

A

Arne Vajhøj

I have an application which runs nicely on Windows CE 5 (uses .NET CF 2.0).
Our sales and service teams would like a demo version of this application to
run on their laptops running Windows XP / 7. Is there a (relatively)
straightforward way to take the latest source of the Windows CE app and
compile a Windows NT version? Using Visual Studio 2005.

I have never written or even seen a .NET CF app.

But I was made to believe that .NET is a subset of full .NET.

And if that is the case then I would expect it to build/run
as is.

So what problems are you seeing?

Arne
 
A

Alain Dekker

Thanks for the responses. The application just crashes horribly as you try
to run it. I suspect part of the problem is that I've had to use several
platform specific P/Invoke calls due to limitations of the CF. For example,
I've declared this for "GetTickCount" for use on WinCE:

[DllImport("coredll.dll")]
public static extern uint GetTickCount();

But the same version on Windows XP would be:

[DllImport("kernel32.dll")]
public static extern uint GetTickCount();

I am assuming I *might* be able to deal with thus using the preprocessor
(??).

I just don't know if that's the only issue I'll have to deal with, hence the
question. For example, I note that when I "Debug" my application in VS 2005,
it wants to deploy it to a Windows CE 5.0 device...and I can't stop it
trying to do this!!

Thanks,
Alain
 
Ad

Advertisements

A

Arne Vajhøj

Anders Eriksson said:

Thanks for the responses. The application just crashes horribly as you try
to run it. I suspect part of the problem is that I've had to use several
platform specific P/Invoke calls due to limitations of the CF. For example,
I've declared this for "GetTickCount" for use on WinCE:

[DllImport("coredll.dll")]
public static extern uint GetTickCount();

But the same version on Windows XP would be:

[DllImport("kernel32.dll")]
public static extern uint GetTickCount();

I am assuming I *might* be able to deal with thus using the preprocessor
(??).

The P/Invoke issue can be solved as described in Anders's link.

http://msdn.microsoft.com/en-us/magazine/cc163387.aspx#S7

To find P/Invoke problems you could try this tool:

http://www.mono-project.com/MoMA

Arne
 

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