Hello, i have written a code in 'C' using visual C++, and i was able to create a DLL out of it.

Now i need to access a method of this DLL, from my C# Main() method. How do i do this?

The steps that i followed so far;
1.) added the DLL as a reference
2.) using "my_dll.h" // on top of the code
3.) tried to access it as follows. my_dll.c_method_name() // but it doesn't work that way

Please help me resolve this.

Recommended Answers

All 2 Replies

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.