moonrise
asked on
RichEdit1.Perform(EM_CANPASTE, 0, 0) <> 0;
In the RichEdit example with Delphi 4 it uses
RichEditEditor.Perform(EM_ CANPASTE, 0, 0) <> 0; to find out if there is something to paste from the clipboard. I am trying to do the same but with a ComboBox but it does not work. Any suggestion ?
RichEditEditor.Perform(EM_
ASKER
I fount this constant to be in Richedit.pas. I created my own constant so it compiles fine. But I don't get the right result like I do with a RichEdit component.
Why do you actually do you need to paste something from the clipborad...Let's say it's a whole file, then what? Everything copied will get into your combobox...
Regards,
Viktor Ivanov
Regards,
Viktor Ivanov
ASKER
There is a PASTE button on my form. This button has to be disabled when there is nothing in the clipboard to paste. My form is a webbrowser and the combobox is the url. The paste can also occur on the web page. It does not matter because all components use the same clipboard. If I had a richedit on that screen I would use it and I would have no problem. Just like I could place a dummy richedit, make it invisible, just to be able to use it to check if there is something in the clipboard.
So the question is why does that work with richedit and not with other components ?
So the question is why does that work with richedit and not with other components ?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Good, it does exacly what I need. In fact it is even better because that way the paste button will remain disabled if there is let say a picture in the clipboard. Thank you.
To see what messages the combobox has look 'em up in the win32 help file
Regards,
Viktor Ivanov