C# call COM components

Now this demand, there is a use VC to write the COM component, which I will call this COM component in C# VS, the reason some structure, function of what, for God to guide how to call, this structure is how to call. . .

Started by Bruno at November 11, 2016 - 11:12 PM

The response to 2013-10-29 15:21:11 was removed by the administrator

Posted by Hale at November 21, 2016 - 11:48 PM

        
        /// <summary>
        /// Disconnect the terminal and serial
        /// </summary>
        /// <returns></returns>
        [DllImport("sms.dll", EntryPoint = "Sms_Disconnection")]
        public static extern uint Sms_Disconnection();

Posted by Winston at November 24, 2016 - 12:37 AM

This I know, but how reference structure?

Posted by Bruno at November 26, 2016 - 1:00 AM

You define, turn around Marshal
C# You can use "dynamic" type 4 or VB.Net, if the types do not match, the runtime error

Posted by Sidon at November 27, 2016 - 1:23 AM

A reference to an instance? Not quite understand

Posted by Bruno at December 02, 2016 - 1:52 AM

Right click the project cited the -> browsing -> determination;

Posted by Cliff at December 09, 2016 - 2:25 AM