Adding scripting support for your application

Source: Internet
Author: User
Tags ole

The code-run effect is shown below:

Introduced

Sometimes we don't need to provide complete scripting support, just as the ActiveX Script Host (script hosting, which may be known as the scripting engine) that this article describes, The SCRIPTCONTROLMACRO program provided in this article shows the simple implementation of scripting support with Microsoft Scripting controls, and the following techniques are included in the code:

Using a file map implementation allows only one instance of the application.

How to read binary registry data with MFC storage

How to save the recovery application window size, location

How to use a different font in a CEditView derived class

How to catch an OLE exception and display an error message

etc...

Preparations before the start

This article assumes that you are familiar with COM, ActiveX controls, OLE Automation, and how to use them in MFC. Because these technologies contain quite a bit of content, you should take a look at the content first.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.