WM_DRAWCLIPBOARD multiple messages

2019-08-17 06:37发布

问题:

I'm working on a small clipboard manager which should remember recent copied text. I'm using Windows system messages for being notified when something has been copied to clipboard by WM_DRAWCLIPBOARD. The problem is some of the applications I use send multiple WM_DRAWCLIPBOARD messages to my application, for instance when I copy something in Chrome web browser it's only one message, miranda's chat window sends 3 of the same messages with the same text to the clipboard viewer's chain. How to avoid this ?

回答1:

Some applications put different versions of the same text on the clipboard (RTF,Unicode,ASCII) Could this be the reason?