register .NET assembly as COM object

G

Guest

hi guys,
how do i register my .NET DLL written in C# as a COM object?

I need to do this so i can call it from classic ASP page.

ive spent hours on this please help!! :) thanks.

Dan
 
P

Peter Foot [MVP]

This is not supported in the .NET Compact Framework. COM interop only allows
you to call COM objects from .NETCF or expose a COM interface when passing
an object to a COM method, you can't create a registerable type. You either
need to write your COM object entirely in C++, or use some form of IPC to
talk to a separate .NETCF process.

Peter
 
R

Ramki

Hi Daniel,

I am also looking for solution of same problem.Eveni created managed COM
interop dll , trying to register in windows CE device . to expose COM object
and call ProgID of dll in ASP file to create object.

Please let me know , how did u get able to do that.Is it possible to do like
this. is there any way i can able to register dll.
Here i smy sample dll lokks like , have class and inetrface


namespace MagnumDevApp
{
[ComVisible(true)]
[Guid("C68CAF28-0DE2-4baf-BBD3-9066B8D7B3AF")]
[InterfaceType(ComInterfaceType.InterfaceIsDual)]

public interface IComcls
{
int GetNum();
}



}

namespace MagnumDevApp
{


[ComVisible(true)]
[Guid("D7A01E18-8C49-4ede-96C9-99889B7AA2EF")]
[ClassInterface(ClassInterfaceType.None)]

public class comcls : IComcls
{

public comcls()
{

}
public int GetNum()
{
return 1;
}
}

}

Please provide me solution to this , i really struck with this.
 
C

Christopher Fairbairn

Hi Daniel and Ramki,

Ramki said:
I am also looking for solution of same problem.Eveni created managed
COM interop dll , trying to register in windows CE device . to expose
COM object and call ProgID of dll in ASP file to create object.

This functionality is not currently supported by the .NET Compact Framework.

Although there is COM interop functionality, there is no support for
registration and activation.

Hope this helps,
Christopher Fairbairn
 
N

Neil Cowburn

Please let me know , how did u get able to do that.Is it possible to do like
this. is there any way i can able to register dll.

COM Callable Wrappers (CCWs) are not supported under the .NET Compact
Framework. Only Runtime Callable Wrappers (RCWs) are supported.
 

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