Home > Back-end >  C builder how to set up a press Enter to send message, press Shift Enter a line break?
C builder how to set up a press Enter to send message, press Shift Enter a line break?

Time:09-25

Do a program, how to set up a press Enter to send a message, and sends the message input box after not line, press Shift + Enter to realizing a line break,

CodePudding user response:

What is the content box? Memo?

CodePudding user response:

Application - & gt; Keyboard message interception OnMessage event handling process, if the Enter key/send a message, if it is Shift + Enter, send Memo1 controls the key message (Enter key), OnMessage capture not use SendMessage messages sent directly to the window, because it's not through the message queue,

CodePudding user response:

reference 1/f, play big shoot early nuclear response:
content box is what? Memo?

Solved meno, but for no apparent reason, add the code behind,

CodePudding user response:

Memo Shift - Enter inside itself can wrap,
  • Related