Skip to main content
16-Pearl
September 12, 2016
Solved

How to create Toolkit dll application as COM Visible?

  • September 12, 2016
  • 1 reply
  • 3688 views

I want to refer the Toolkit dll application in my C# Project. So I want to make it COM Visible. Any Idea's


This thread is inactive and closed by the PTC Community Management Team. If you would like to provide a reply and re-open this thread, please notify the moderator and reference the thread. You may also use "Start a topic" button to ask a new question. Please be sure to include what version of the PTC product you are using so another community member knowledgeable about your version may be able to assist.
Best answer by TomasLoun

You don't need to create COM interface to use application in C#. It is better to create managed interface to .NET - An Overview of Managed/Unmanaged Code Interoperability

We already have our library with many Pro/Toolkit functions which we are using in C#

1 reply

TomasLoun1-VisitorAnswer
1-Visitor
September 23, 2016

You don't need to create COM interface to use application in C#. It is better to create managed interface to .NET - An Overview of Managed/Unmanaged Code Interoperability

We already have our library with many Pro/Toolkit functions which we are using in C#

16-Pearl
September 27, 2016

Hi Tomas,

I have tried many ways. I have created Win32 application executable file it is working fine.

But I am planning to create dll file for my C Sharp Project. Whenever I Calling my DLL in C# Project I am getting the below Error. May you help in this situation?

Error10error LNK2019: unresolved external symbol _ProEngineerConnectionStart referenced in function "public: __thiscall myClass::myClass(double,double)" (??0myClass@@QAE@NN@Z)C:\TOOLKIT DEVELOPMENT\ASYNCHRONOUS APPLICATIONS\TEST 4\AsyncTestDll\AsyncTestDll\AsyncDll\main.objAsyncDll

LOG FILE :

main.obj : warning LNK4075: ignoring '/EDITANDCONTINUE' due to '/INCREMENTAL:NO' specification

     Creating library C:\TOOLKIT DEVELOPMENT\ASYNCHRONOUS APPLICATIONS\TEST 4\AsyncTest4\Debug\AsyncDll.lib and object C:\TOOLKIT DEVELOPMENT\ASYNCHRONOUS APPLICATIONS\TEST 4\AsyncTest4\Debug\AsyncDll.exp

main.obj : error LNK2019: unresolved external symbol _ProEngineerConnectIdGet referenced in function "public: __thiscall myClass::myClass(double,double)" (??0myClass@@QAE@NN@Z)

main.obj : error LNK2019: unresolved external symbol _ProEngineerConnectionStart referenced in function "public: __thiscall myClass::myClass(double,double)" (??0myClass@@QAE@NN@Z)

C:\TOOLKIT DEVELOPMENT\ASYNCHRONOUS APPLICATIONS\TEST 4\AsyncTest4\Debug\AsyncDll.dll : fatal error LNK1120: 2 unresolved externals

16-Pearl
September 28, 2016

Hi Tomas,

Finally my DLL works fine with C Sharp Application...