I need my control to fill the text property of other controls when an event is shooted (as the Input

A

Arijull

Hi.

I need to do something that it's a little dificult to explain....
Please be patient :)

I have a control (my control is a calculator).
This control returns a value (the result).

I need that:
If when i call this control (from a menu), there is a cell, a textbox,
or any control that it's editable focused (active in the form), then
the text of that control has to be fill with the calc return value.

My control shoukd work as the input panel works... If a textbox it's
focused, when you touch the letters of the input panel, they are
showed in the textbox..... The same happens if a grid's cell is
focused, then that cell is filled when you press the input panel
buttons.

My calc control has an "OK" button, I want that when i press that
button, if a textbox in my form is focused, the the text property of
this textbox must be the calc result.

What I need to know, is if there is a way to call to some P/Invoke or
something like that from my control, and then the problem is solved.
Or if I need to do something diferent. I think that my control should
work similar to the input panel (when the input panel fills the text
property of some control)

Thanks a lot for your time!
 
G

Guest

The problem is that when they click your control, by default it will get
focus, so there will be no other control focused to receive the input from
it.


--

Chris Tacke, Embedded MVP
OpenNETCF Consulting
Managed Code in an Embedded World
www.OpenNETCF.com
 
A

Arijull

I understand that.

That takes me to another question: how does the input panel manage
that?
Can I do the same that the input panel does?

I think that I need my control to work as the input panel does, that's
why I put that example.

Thanks!
 
P

Paul G. Tobey [eMVP]

The input panel isn't made up of controls and doesn't accept the focus, so
tapping on it does nothing to the focus.

Paul T.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top