Conclusion

This chapter has shown several mechanisms for using COM components from your applications. First, COM interfaces were accessed directly using CoCreateInstance, AddRef, Release, and QueryInterface. Next, smart pointers were used to alleviate the responsibility of managing reference counting. Automation provides a structure-based calling mechanism that allows applications a non-function-based mechanism for calling functionality in an Automation object. Code for calling IDispatch::Invoke directly was shown and then the MFC COleDispatchDriver derived classes were used to make calling Automation objects easier.

Throughout this chapter, examples showing the accessing of Pocket Outlook functionality through COM and Automation interfaces were presented. Wherever possible an application should place contact information in Pocket Outlook rather than maintaining the data in separate databases.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.222.115.120