Call managed functions from unmanaged

  • Thread starter Thread starter Mhaxx
  • Start date Start date
M

Mhaxx

How to call .NET CF functions from (managed, Windows CE based) code?

Mhaxx
 
from (managed, Windows CE based) code?

Sorry, from unmanaged code..

Mhaxx
 
IPC via window messages or point-to-point messasge queues are pretty

Oh..
much your only options.

Is there any example about what you say? I'm a beginner and I really don't
know so much about IPC, etc

Mhaxx
 
IPC via window messages or point-to-point messasge queues are pretty

Oh..
much your only options.

Is there any example about what you say? I'm a beginner and I really don't
know so much about IPC, etc

Mhaxx
 
IPC via window messages or point-to-point messasge queues are pretty

Oh..
much your only options.

Is there any example about what you say? I'm a beginner and I really don't
know so much about IPC, etc

Mhaxx
 
Neil, you're right, I know but at the moment I was only looking for an
example, some code already written.. this is my need.

Thanks,

Mhaxx
 
Mhaxx said:
How to call .NET CF functions from (managed, Windows CE based) code?

Mhaxx

use #pragma managed/#pragma unmanaged in your C++ program(cpp) file.
in managed block you can make a function that do your .NET CF and then
call this function from unmanaged code.
 
Hi,

superclass said:
use #pragma managed/#pragma unmanaged in your C++ program(cpp) file.
in managed block you can make a function that do your .NET CF and then
call this function from unmanaged code.

Managed C++ is not a supported language for the .NET Compact Framework. So
this solution will not work.

Hope this helps,
Christopher Fairbairn
 
Christopher Fairbairn said:
Hi,



Managed C++ is not a supported language for the .NET Compact Framework. So
this solution will not work.

so why I can still compile program with managed/umanaged code with Visual
Device Compiler??
 
Compile != run. The CF doesn't support all of the opcodes that managed C++
creates, so compile all you want, the CLR can't interpret all o the IL and
trying to run may fail. I say "may" becassue it's quite possible to create
a simple app in managed C++ that doesn't contain unsupported opcodes, but
there's no way to prevent it, so you will undoubtedly get to a point in any
real-world application where the opcode is used and the app will not work.


--

Chris Tacke, Embedded MVP
OpenNETCF Consulting
Giving back to the embedded community
http://community.OpenNETCF.com
 

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

Back
Top