Send clipboard text as key stokes.

albertstc01

Member
Licensed User
Longtime User
Hi,
I have a Raspberry Pi set to run Ubuntu Mate. I have it to load X11 VNC server.
I use an Android 7 inch tablet with a VNC client running so the Raspberry can be viewed on a 7 inch screen. I also run a VNC clients on my HTC Mantle hand held computer and I use this with it's stylus on it's small screen to create a comfortable wireless keyboard for the Raspberry Pi.

The VNC client programs on the Mantle do not have menu items for sending text from the client's clipboard to the VNC servers as key strokes. This means prepared text from Word or Spreadsheet cannot be sent to the Raspberry Pi later when convenient.

I'm looking for a program or programming to send clipboard text to any other program's window on the Mantle, in my case a VNC client.

I have used a program which does send GPS text strings from its port setting to the Mantles VNC client program window and transmitting it as keystrokes to the VNC server on the Raspberry. So I'm looking at the idea of programming that sends text to a com port and some type of serial wedge programming to send text as key strokes to another programs window.

If any has any information where information can be found to do this it would be appreciated.

Many Thanks in Advance.
Regards albertstc01
 

albertstc01

Member
Licensed User
Longtime User
Many thanks for your link but the programming I'm looking for is the HTC Mantle which has the Windows Mobile 6.1 operating system.

Regards albertstc01
 

albertstc01

Member
Licensed User
Longtime User
It's not clear in your original post what it is that you actually want to do. Do you want to access the clipboard from Basic4ppc, or do you want to access a serial port, or do both?
Hi agraham,
Sorry to take so long to respond.
Thanks for your interest and response.
Your query
>Do you want to access the clipboard from Basic4ppc, or do you want to access a serial port, or do both?

I want to access the clipboard then send the text as key board presses to a VNC client's window running on a HTC Mantle. This so the text is sent to another computer running a VNC server as if it was from the keyboard. The VNC client does not have clipboard sharing or a menu feature for pasting text to the VNC server.

Using shortcut key presses on the on screen keyboard in the VNC clients window to paste text such as “CTRL V” will not send text from the HTC's clipboard. If it worked at all the shortcut key presses would be sent to the VNC server and clipboard text from the server's clipboard would paste.

Browsing other languages for Visual Studio for both Visual Basic and C# use a “sendkeys” function. Unfortunately the “sendkeys” function was not made available for the “compact .net framework”. Some kind work around will be needed.

So not to confuse please leave serial port thoughts aside except to say a program “CeWedge” will send text from a serial port as if from keyboard.

Thanks again for your interest
Regards albertstc01.
 

agraham

Expert
Licensed User
Longtime User
I don't think any of the Basic4ppc libraries are still available on the forum so I have attached some here.

The Clipboard library is a simple library will let you interface to the clipboard and set and retrieve the content.

I am rusty on Windows Mobile but the only way I can think of to send keyboard presses to a window is by using Window messages. The WindowMessage library lets you do this but you would have to find out the intricate details yourself - I don't have any information to hand. If you try to go this route the dzWH-3 library might be useful instead for low level interaction with windows and sending messages.
 

Attachments

  • Clipboard1.0.zip
    3.2 KB · Views: 563
  • WindowMessage1.0.zip
    21.7 KB · Views: 540
  • dzHW-3.zip
    15.2 KB · Views: 556
Top