Summary

team lib

This chapter has introduced the Platform Invoke mechanism, which .NET provides to let .NET code call unmanaged functions in DLLs.

Platform Invoke can be used from all .NET languages using the DllImport attribute, and you have seen examples of how to do this in Visual Basic .NET, Visual C#, and managed C++. Visual Basic .NET also offers the Declare statement as a front end to Platform Invoke, which emulates the Visual Basic 6.0 Declare construct. Managed C++ code can use the It Just Works mechanism, which allows C++ developers to call unmanaged functions simply by including header files and linking with the appropriate libraries.

The basics of Platform Invoke presented in this chapter will let you work with a large number of unmanaged functions. Chapter 13 discusses more advanced aspects of interoperability.

 
team lib


COM Programming with Microsoft .NET
COM Programming with Microsoft .NET
ISBN: 0735618755
EAN: 2147483647
Year: 2006
Pages: 140

Similar book on Amazon

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net