PlanetSquires Forums

Support Forums => Other Software and Code => Topic started by: Nathan Durland on November 18, 2014, 01:25:24 PM

Title: Capture Paste to Textbox
Post by: Nathan Durland on November 18, 2014, 01:25:24 PM
I have a text box in my app, and by capturing the WM_CHAR message I can limit the data to the characters I want, can change some on the fly.  However, pasting data into the text box seems to bypass that.  How can I capture that event?  Looking around, it seems I need WM_APPCOMMAND in my _CUSTOM processor, but I'm struggling on how to snag it, and what to do once I do.

Any pointers appreciated.
Title: Re: Capture Paste to Textbox
Post by: Wilko Verweij on November 18, 2014, 06:01:47 PM
EN_CHANGE event?
Regards, Wilko
Title: Re: Capture Paste to Textbox
Post by: Eddy Van Esch on November 18, 2014, 07:16:35 PM
Capture WM_PASTE event, copy and (possibly) modify clipboard content before pasting?
Just a suggestion. Haven't tried this myself.
Title: Re: Capture Paste to Textbox
Post by: Nathan Durland on November 18, 2014, 09:25:32 PM
Quote from: Eddy Van Esch on November 18, 2014, 07:16:35 PM
Capture WM_PASTE event, copy and (possibly) modify clipboard content before pasting?
Just a suggestion. Haven't tried this myself.

That's a forehead slapper -- I never thought to search for such an event...

off to test.