In win32 C ++, how do I enable a static text control to copy text?

I am writing a simple win32 application that has a window and static text, now I want the user to be able to copy the text with his right click (check and copy) how can I do this?

LANGUAGE LANG_NEUTRAL, SUBLANG_NEUTRAL
IDD_DIALOG1 DIALOG 0, 0, 369, 318
STYLE DS_3DLOOK | DS_CENTER | DS_MODALFRAME | DS_SHELLFONT | WS_CAPTION | WS_VISIBLE | WS_POPUP | WS_SYSMENU
CAPTION "Win32 demo"
FONT 8, "Ms Shell Dlg"
{
     LTEXT           "Questions to dddd@gmail.com", IDC_STATIC, 96, 87, 150, 8, SS_LEFT
}
+5
source share
1 answer

You cannot do this with static text. In particular, you cannot select text. Instead, you should use a read-only control.

+5
source

All Articles