a question for Erel

Ricky D

Well-Known Member
Licensed User
Longtime User
Hi mate.

I'm wondering how to do a sendkeys in B4PPC.

I can create a control either in vb or C# that would fire a KeyPressed(key) event based on what key I press.
In my B4PPC code I'd get the key but how do I send it to the control that has focus?

I've searched the forum for sendkeys and got 1 entry in Italian.

I looked at the link but I'm not sure how to make it work on the B4PPC side.

regards, Ricky

I created a quick custom panel with a button.
When I click the button my textbox loses focus. I don't want it to lose focus. Not sure how to change this behaviour.

Also using C# how do I pass back the button pressed on my sip in the KeyPressed event?
 
Last edited:

Ricky D

Well-Known Member
Licensed User
Longtime User
no i haven't but

No I haven't but what I'm forced to do is write my own sip based on 2 panels - 1 for abc and the other for numeric.

Either that or send the built in sip something to click the little 123 button it has if I make the keyboard large.

I'd like to show the number pad when a number textbox receives focus and show the alphabet when a text textbox receives focus.

If I create my own sip in C# I notice that when I click one of its buttons the button gets focus and the control being typed into loses it.

Could I detect a mouse press on the panel on say a label and not have it receive focus?

regards, Ricky

p.s i looked at the hardware and it looks like it will do the key sending. Thanks for that. Now to solve the focus issue

I've figured it out. using dzEventsMagic and Hardware I have put labels on a panel that will sit where the sip would sit and it does just what I want - yay! Now to code it all - I need 1 dzEventsMagic object per key and the corresponding dz_MagicEvent sub. In the sub i use hardware to send the key to the control using the KeyPress method.

I can do all this in B4PPC without having to resort to creating a new dll.
 
Last edited:
Top