Click here to Skip to main content
15,887,746 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello
I ask something like this before but i have another problem
I made a project in Visual Studio 2010 a class library and make a COM component, now i want to call this methods from Clarion, i put the dll in the Clarion project folder but doesn't work, Which files i have to use, how i do that?

this is the code i use in clarion but don't do anything


WorkOpenWin                routine
   data
Interop01                  long
   code
   Interop01 = CREATE(0, CREATE:OLE)
   Interop01{PROP:Create} = 'Interop01.Interop01Class'
   Interop01{'CallDotnet("Message from Clarion")'}


thanks
Posted

From what little I can tell by your question, you just put the dll in the folder and expected it to work. You need to add a reference to the dll by right clicking on the References folder, and selecting "Add Reference...". Then click "Browe..." button and select the dll in the dialog. Then you need to click the "Add" button on teh Add Reference to .... That should solve your problem.
 
Share this answer
 
Comments
Estephanny_777 22-Jun-12 14:38pm    
thanks Clifford Nelson, but how I reference a dll created in .NET in the Clarion aplication?
I know how do this from the visual but from the Clarion I have no idea
First of all, consider using Clarion.NET:
http://www.softvelocity.com/ClarionNet/ClarionNET.htm[^].

Using .NET assemblies by native code is not easy, and I don't like COM way as intrusive and kind of obsolete. Please see my past answer and CodeProject articles I reference in them:
loading C# DLL in MFC[^],
How can I use a dll created in Visual Basic 2008 in Visual Basic 6.0[^],
Call Managed DLL written in C# from Unmanged Code VC++[^],
API's in .Net: Managed or UnManaged Code[^].

—SA
 
Share this answer
 
Comments
Shahin Khorshidnia 23-Jun-12 3:18am    
I think it helps very much.
+5
Sergey Alexandrovich Kryukov 23-Jun-12 11:57am    
Thank you, Shahin.
--SA
Espen Harlinn 23-Jun-12 8:56am    
Nice links :-D
Sergey Alexandrovich Kryukov 23-Jun-12 11:57am    
Thank you, Espen.
--SA
Estephanny_777 25-Jun-12 9:58am    
Thank you, Sergey that's help me a lot =)

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900