Problem with clipboard
Posted on 1999-07-03
I'm trying to watch the clipboard and see if the user tries to copy a text in a TMemo. I've started with this code that will be run when the clipboard is used and it should get the content of the clipboard so I could compare with the text in TMemo, but instead it raises an exception every time it is used, what is the problem and how should I write this procedure instead?
If IsClipboardFormatAvailable(CF_TEXT) then begin
memoryplace := GetClipboardData(CF_TEXT);
If memoryplace <> NULL then begin
test := GlobalLock(memoryplace);
If test^ <> NULL then begin