How to call/load .net dll(C#) from c++ code?

Posted by TajByte, 03-22-2007, 04:50 AM
How to call/load .net dll(C#) from c++ code?

Posted by cis4life, 03-24-2007, 02:11 PM
first you will have to add the dll as a ref. in your "Reference" area of VS.Net then, lets say in the dll the namespace is MyNameSpace and the class is MyClass, then you would write MyNameSpace.MyClass myObj = new MyNameSpace.MyClass(); (This can vary if you have an overloaded constructor and so forth) This will create a new MyClass Obj named 'myObj'. Now you can call that objects functions by writing... myObj.MyFunction(); Its kind of hard to explan without seeing the dll, also remember that only 'public' classes, functions, and variable can be used, if you defined them in your code as 'private' you won't have access to them directly. Cedric

Hasznosnak találta ezt a választ?

 Kinyomtatja ezt a cikket

Olvassa el is

Apache not recognising my .php files.

Posted by SuperSub, 06-29-2008, 06:43 AMHey guys, Yesterday I was told by my hosting provider...

Does the use of partitions prevent hackers from getting access to the linux server?

Posted by lifeonfire, 05-07-2007, 11:11 AMDoes the use of partitions prevent hackers from getting...

kernel exploit!

Posted by tkanaco, 06-27-2008, 11:27 PMHow Can i translate An Kernel Exploit to secure my server...

sshd has failed, please contact the sysadmin

Posted by X-x-X, 01-23-2007, 12:31 PMi have problem in SSH if i want to restart it its say :...

Cronjob issue

Posted by CymraegWalesHosting, 11-16-2012, 11:25 PMHi all, Hopefully this is a simple fix....