Cheetah mfc--Send Message SendMessage PostMessage

Source: Internet
Author: User

To add a picture control:



The effect is as follows:
Add a text description first:

Open the header file definition variable:
Add the following code in the dialog initialization code section:

Drag when the left mouse button is pressed down Lbuttondown:
Set Boolean variable record, set capture, set cursor:

When the left mouse button bounces:

If you are in capture state: The release capture Boolean variable is set to pseudo-define the mouse coordinates by converting the mouse coordinates from the original form client area to the screen area by the point gets the window handle type conversion in the text box to display the window handle
The effect is as follows:
Gets the window class name from the window handle:
The window handle is then sent by the Wm_gettext message to get the window caption "
The effect is as follows:


Double-click the Button1 button: Modify the title:



Send shutdown message:


























From for notes (Wiz)

Cheetah mfc--Send Message SendMessage PostMessage

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.