Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
HowTo force Richtextctrl to react on keyboard '{CTRL+V}'
Message
General information
Forum:
Visual FoxPro
Category:
ActiveX controls in VFP
Miscellaneous
Thread ID:
00850053
Message ID:
00850268
Views:
26
Good! So RTF has its own window, therefore oShell did not work; and probably keyboard ... also require activating rtf window first.

Would be good to understand how to activate RTF window: positioning mouse manually over RTF works, but when I programmatically put mouse pointer over RTF and try mouse click, it does not.

>Hi Yuri,
>
>I run some test and it looks like you've to send WM_PASTE message for this to work.
DECLARE integer SendMessage IN WIN32API ;
>		integer hwnd, integer Msg, integer Wparam, integer lParam
>#define WM_PASTE	0x0302
>SendMessage(Thisform.oRTF.Object.Hwnd, WM_PASTE, 0, 0)
>
>
>>Will it somehow differ from oShell = CreateObject("WScript.Shell"), oShell.sendkeys(to window) that I already tryed?
>>Not quite sure how to send it to control (is control.setfocus, and send to window enough?).
>>
>>>Hi Yuri,
>>>
>>>I would try to send 'CTRL+V' directly to control using SendMessage Win API.
>>>
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform