question about tlbimp

F

Felipe Garcia

We use some unmanaged components in our project.
Until now, we were importing this components with VS.NET IDE Help, I mean,
through "Add Reference" this works fine for us. But now we decided to create
the Assemblies with the tlbimp tool help.
We created the assemblies, but they have different content, events
signatures changed and so on.
And for example, we have some legacy projects that makes use of the
MsMask32.ocx, and when we import MsMask32.ocx through tlbimp we found out
that the Validated Event went away.
My doubt is, how VS.NET IDE imports this components and creates its interops
? Is there a way to achieve this with the tlbimp tool help ?

I'm using the following command to import:

tlbimp MsMask32.ocx /primary /keyfile:key.snk /out:Interop.MsMask32.ocx
 
M

Mattias Sjögren

My doubt is, how VS.NET IDE imports this components and creates its interops
? Is there a way to achieve this with the tlbimp tool help ?

For ActiveX controls you should use Aximp.exe instead of Tlbimp.exe.

When you reference a regular COM component from VS, it's like running
Tlbimp.exe with the /sysarray option.



Mattias
 
F

Felipe Garcia

Thanks Mattias.
It solved my problem.

Mattias Sjögren said:
For ActiveX controls you should use Aximp.exe instead of Tlbimp.exe.

When you reference a regular COM component from VS, it's like running
Tlbimp.exe with the /sysarray option.



Mattias
 

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