MFC Custom Keyboard DLL Accessed from Application Dialog Box - dll

The overall goal is to be able to access a pop-up keyboard through an application that I am making in MFC.
I have created a dialog box with an empty text field. I would like to be able to click the empty field and have an onscreen keyboard to enter in the data field.
Is there list of functions or tutorials that anyone can provide me with to be able to perform this function? Ultimate I will be making the keyboard from scratch, so any guidance would be useful.

My first thoughts (I might be wrong someone might correct me if i am wrong.)
1)Create your Keyboard Ui in an MFC DLL and export the KeyBoard Functions like LaunchKB(Int screenx,int screeny) and CloseKB()
functions.
2)I would subClass CEdit and CRichedit such that when the edit control gains or loses focus it would call LaunchKB() function with windows ScreenX coordinates where the keyboard has to be displayed or CloseKB().
3) A callback function registered to dll ,which would get called for every click on the keyboard with characters clicked and these characters are to be displayed in the edit control.
This is just my thought ,there may be better ways to implement as well.

Related

What is the recommended way to enable a single focus for all keyboard input in Winrt?

In a C++/winrt program with many xaml controls and panels I'm wondering if there is a recommended way to direct all keyboard input to one handler? And to restore that if the user temporarily uses a TextBox or other text input? I've found that handling keydown/keyup events in the MainPage works only until one uses the mouse to interact with any of the program's various Stackpanels, etc., after which it doesn't seem possible to restore focus to the MainPage. This is a program in which the keyboard is used for more than entering text in fields; it's used to trigger other events.

AutomationPeer - how to show data of elements not on the control?

I want to write an AutomationPeer for my custom control in WPF.
Now, I want to show textBlocks \ TextBoxex that are not actually visible on my control.
I know how to override the method GetChildrenCore().
My problem is that when i run the playback (coded ui record) - it's trying to find a control not vissible on the window. Have you got any ideas?
You can set the SearchConfiguration VisibleOnly on the Coded UI control. Also, the UITestControl.FindMatchingControls method can let you know if the search properties are too ambiguous. Coded UI stops looking for a control after the first instance of a matching control is found.
inspect.exe can shed light on a form and how Coded UI may be seeing the control.
Try opening the Designer.cs and see the hierarchy and what Coded UI is trying to find.

How to determine which form controls the keyboard input on VB.net

I'm developing a VB.net windows application and I have some issues with the keyboard input.
My application has different forms and I'm showing and hidding them with the user interaction. One of the inputs comes from the keyboard, and here is where I have a problem.
When I hide a form and show the next one, most of the times the new-shown form does not receive the keyboard input until I click somewhere on it.
I assume that the problem is that the new form I'm showing is not the "selected application" for windows until the user interacts with it by clicking on it, but I don't know how to set this "property" by code.
I tried with focus and select on the whole form (Me.select/focus) and in some form's control (me.lbl_xxx.select/focus), but I did not get any result.
Can anyone explain me how to control which application/form gets the keyboard input on windows?
Thanks
David
You can't really interact with a label so the input focus won't be set properly.
Focussing a specific textbox on your form on the other hand should just work fine.

Capital Only Edit Control

Having a bit of a problem doing this and not sure of it can be done. I have an edit control that a user types into, I would like for the input to be all in capital letters. I tried having a custom action on the edit control to get the property, convert to capital letters and set the property again each time a letter is set but it does not work. I guessed it wouldn't but no harm in trying..:)
Has anyone else solved this? I would like to do it without having a button to press if possible. The dialog in question is a twin dialog if that helps at all.
Thanks for your help
It's not possible using the native built-in Windows Installer UI. The underlying MaskedEdit Control is primitive. There are no events to tie into to validate and modify as the characters are entered. You can only ToUpper() the property when the user clicks Back or Next.
The alternative would be to go with an external UI handler which is a lot of learning and work.

Is it possible to have an extension library dialog box within a repeat control?

I'm running with an 8.5.3 UP1 server and I have a need to have many dialog boxes (for confirmation purposes) for a whole bunch of "action buttons" on an xpage. The code for these dialog boxes is almost exactly the same with the exception of the confirmation message being different and the client-side JS function they are calling if the Yes button is selected.
Since I really hate repeating code over and over, I was wondering if it is at all possible to put a xe:dialog control within a repeat control and specify the message and function call from an array of values? I know I can't compute the ID of the dialog control and without that I'm not sure how I would reference the dialog to open and close it.
Any ideas? Thanks
Yes, this is possible.
Make sure that you specify that the dialog box's property for keepComponents is set to False. You don;t have to do anything special for opening or closing the dialog box, just use whatever ID you give the dialog box in you client-side action to open the dialog box in the repeat such as XSP.openDialog('#{id:myDialog}')
The XPages renderer will automatically calculate the correct ID names for you.