COM / DCOM on Windows CE 3 
Author Message
 COM / DCOM on Windows CE 3

We are trying to get DCOM working on our Windows CE 3 device. I have added
the DCOM and ATL modules to our platform. Our first attempts at getting DCOM
to work failed. Our server component created with ATL and client work on the
ce device, but when we move the client to another machine it fails.

After further research we are learning a bit more about the COM / DCOM
implementation on CE 3...

Most of what we have done in the past on windows has been ATL using type
library marshalling. From what I understand type library marshalling is not
supported in CE. I have several questions:

We have to create and register proxy - stub .dll's on both the server (ce
device) and the client (windows workstations)?

No make file is generated by the eVC ATL App wizard. If we need to create
our own, what needs to be in it?

Do we need to compile the proxy - stub .dll for the server in eVC and the
proxy - stub .dll for the client in VC++?

Since type library marshalling is not supported do you recommend using dual
interfaces or just single interfaces?

Do I need to add anything more to the platform build besides the DCOM
module?

When we try to build our com server it downloads to the ce device, but the
debug version will not register. Only the min dependency build will
register. What is missing?

I see a reference for a DCOMCNFG for ce, but it is a .lib file. Does this
mean it is only an API into working with DCOM security on the device? Is
there an interface written in to this API?

Do you have any suggestions about working with security?

Our first attempt at contacting our com server over the wire resulted in an
error that the RPC server did not exist. Any thoughts?


Software Engineer & Network Administrator
Spitz, Inc. [ http://www.*-*-*.com/ ]



Mon, 15 Sep 2003 22:54:47 GMT  
 COM / DCOM on Windows CE 3



Quote:
> ..., but when we move the client to another machine it fails.

> We have to create and register proxy - stub .dll's on both the server (ce
> device) and the client (windows workstations)?

Yes. If you create a DCOM server on Windows CE, you create the stub with eVC
and the proxy with VC++.

Quote:
> No make file is generated by the eVC ATL App wizard. If we need to create
> our own, what needs to be in it?
> Do we need to compile the proxy - stub .dll for the server in eVC and the
> proxy - stub .dll for the client in VC++?

You need proxy and stub, compiled with different tools. For a DCOM server on
Windows CE we suggest to create a eVC project for the stub and place it in
the same workspace as the server. With the dependencies in the workspace you
compile the stub if needed.
The stub project contains the files
- YourServer_p.c
- YourServer_i.h
- YourServer_i.c
- dlldata.c
- YourProxyStubProjectName.DEF, containing:
    LIBRARY      "YourProxyStubProjectName"
    EXPORTS
         DllGetClassObject    PRIVATE
         DllCanUnloadNow      PRIVATE
         GetProxyDllInfo      PRIVATE
         DllRegisterServer    PRIVATE
         DllUnregisterServer  PRIVATE
- a #define REGISTER_PROXY_DLL

On the PC an identical project for the proxy. If you place it in the same
workspace with your client, you can update it automatically with the project
dependencies in the workspace.

Quote:
> Since type library marshalling is not supported do you recommend using
dual
> interfaces or just single interfaces?

There is no marshaller for IDispatch implemented by Microsoft. So you must
use the custom interface only.

Quote:
> Do I need to add anything more to the platform build besides the DCOM
> module?

Make sure you have secur32.dll, schannel.dll and ntlmssp.dll in your
platform.

Quote:
> When we try to build our com server it downloads to the ce device, but the
> debug version will not register. Only the min dependency build will
> register. What is missing?

Have you placed all DLLs in your platform, that the Dependency Walker is
reporting?

Quote:
> I see a reference for a DCOMCNFG for ce, but it is a .lib file. Does this
> mean it is only an API into working with DCOM security on the device? Is
> there an interface written in to this API?

Look at %_WINCEROOT%\PUBLIC\DCOM\SDK\SAMPLES\DCOMCNFG

Quote:
> Do you have any suggestions about working with security?
> Our first attempt at contacting our com server over the wire resulted in
an
> error that the RPC server did not exist. Any thoughts?

For a simple launch of the server you can set the DefaultAuthenticationLevel

Helge Kruse
FORTecH Software



Tue, 16 Sep 2003 14:50:56 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. DCOM for Windows CE 3.0

2. Marshal BSTRs for DCOM under Windows CE 3.0

3. Marshal VARIANTs for DCOM under Windows CE 3.0

 

 
Powered by phpBB® Forum Software