How to disable the default keyboard in windows phone - xaml

I don't the default keyboard to popup when giving focus to the textbox in windows phone. Didn't find a way to disable the keyboard. Is there a way to disable it ?
I also tried to extend the textbox and in OnFocus removed the base.OnFocus(), which effectively removes the keyboard. But all other textbox features are also not working. Any pointers regarding this will be really helpful.
Thanks
Kumaran

Related

Make a context menu on a NotifyIcon ALWAYS show hotkey underscore

I appreciate that when asking for help on this forum, the etiquette is to show what you've tried to do and then explain what's not working; instead of just asking "how do you do XYZ" - but this question is a bit of the latter ... so not sure if this question will get closed, before anyone suggest an answer ?!
I have VB.NET Winforms application has a ToolStripMenuItem with various options on it and some of them have an ampersand before their titles, so that they will appear as hotkeys when the user presses the ALT key. These work as expected.
I also have a NotifyIcon on the form, with an associated contextMenuStrip and again options on that menu and some set-up as HotKeys (eg &Exit ). But the hotkeys on the NotifyIcon do not appear and obviously if the user clicks the ALT key, then the menu disappears. The hotkeys do work, but the user needs to know what they are, because they don't see the underscore character.
Now on my PC, I have about a dozen programs in the system tray, such as Outlook etc and non of them show the underscore character under any of their menu options - so that gave me the idea that it wasn't possible .... BUT the icon for Skype Business; does show the underscores (irrespective of pressing the ALT key), so I was wondering if anyone knew how Microsoft accomplished that ?
Cheers,
Chris.

Hide the OK button in windows mobile 6.5

I have a winmo application running on win mobile 6.5 using the 2.0 ce framework:
On some forms, I make use of the menu bar to have custom menu items, as seen below
The "More" and "Cancel" buttons have events wired up so that I can actually make the form behave how I want to. But the problem is the "OK" that is always there by default and just closes the current form. I want to remove this completely so that it looks like this
:
But from what I have been researching so far, it is impossible. I have come across solutions to remove the whole menu bar (I still need the other buttons) or to disable the OK button (but even having it there will confuse the users)
Is this possible?
would be cool to also remove the windows "start" button, but not necessary
You can "dynamically" show/hide the Star icon when using small code BEFORE the window/form is created: http://www.hjgode.de/wp/2012/05/10/windows-mobile-kiosk-mode-series-part-1/
The trick is to just change one registry key BEFORE create windows/form:
[HKEY_LOCAL_MACHINE\Software\Microsoft\Shell\BubbleTiles]
"HardwareStartKeyEnabled"=dword:00000001
set to 1 to hide the start icon for new windows and set to 0 to have new windows show a start icon.
The change will NOT affect already open/created windows/forms. Only newly ones will be affected.
To Hide/disappear the Ok button or x (close) button,
Enable, controlbox=false.
To disappear/Hide the whole header or menu bar,
Use, WindowState=Maximized.

Disable On-Screen-Keyboard

I'm developing a Windows Store app for an embedded application where the only input device is a small touchscreen. For this reason I'm developing my own number and text entry controls that match the visual look of the application and work better on the small screen. Is it possible to prevent the Windows 8 on-screen keyboard from appearing when a textbox gets focus?
You can't, it's a user preference as of now.
Similar question is found here
From Hanselman
Unfortunately there is no checkbox or "just turn it off" way to
disable the keyboard with a supported option.
However, there is a way to effectively disable the keyboard by
stopping the service that controls it.
Press the Windows key + W Type "services," and press Enter Scroll down
to "Touch screen keyboard and handwriting panel" You can either right
click and "Stop" or you can double-click and change it from
"Automatic" startup to "Manual."

Check if software keyboard is open in Windows Phone 8?

I want to check if the software keyboard is open in Windows Phone 8. I have found some sparse information that this is possible using CoreWindow.IsKeyboardInputEnabled, but I can't find any way to implement this. I have found sample code only for C++, which I don't understand at all.
I use VB, however I can read C# enough to figure it out if I can get a C# example.
Whatever I do I always get a null/nothing value. The following code compiles and runs, but c is 'nothing' when the app crashes at the if c.IsKeyboarInputEnabled... line.
Dim c as CoreWindow
c = CoreWindow.GetForCurrentThread
if c.IsKeyboardInputEnabled then...
I know I need to give 'c' a value, but can't figure out how. I've also tried:
Dim c as CoreWindow = New CoreWindow
which the editor flags as an error and thus won't compile.
If it's relevant, what I am trying to do is ensure my navigation is consistent. Currently, a tap on a particular screen element should close that element. However, if the keyboard is open, I want that tap to simply close the keyboard and leave the tapped item open. I believe this is the more intuitive and consistent approach for the user.
I think the only way to achieve this functionality is to know if the keyboard is open before determining what to do with any open panels.
e.g.
[when screen tapped and a popup is expanded]
If [keyboard visible] then [close keyboard] else [close tapped item]
I don't think there is any official API to detect the opening and closing of the SIP but one workaround might be to check if any of your TextBoxes have focus.
You can do this by overriding GetFocus and LostFocus for each TextBox.
To close keyboard, just set the focus to the ContentPanel(or any other grid).
Let me know if this works.

Binding key combinations to your application

How can I bind a key combination to my vb.net application? I know it has SOMETHING to do with the registry, but I have no earthly idea what or how to go about doing this. I want the user to be able to hit those keys when the app is open and have it execute my function, but not while the app is closed.
Thanks for the help!
If you are using a dialog, then you can put '&' into the text for some controls (buttons, checkboxes, radio buttons, etc) and this will cause Alt plus the next character in the text to be used as an accelerator/shortcut. i.e. "&Open" would activate the Open button if you press Alt+O. "Op&en" would activate if for Alt+e.
Beyond that, as Jason Irwin said, you need to add an event handler to your Form for KeyDown or KeyPress events, and then check if the keypress is the key combination you are interested in. This will only work if the user activates your form (clicks in it to give it the input focus. If they put it behind another window, it will not react to the key presses)
If you don't want to show a form, or want to react to keypresses when you're not the input-focus application, then it gets a bit more complicated (you either need to use a hidden form or a keyboard hook)
edit
OK, it looks like you want a keyboard hook. This looks like a good article.
It depends on what you are trying to do:
If you have a gui application and you want to handle key events then you can do that in a keydown eventhandler
If you want to do more low-level stuff and have an application that will intercept all key strokes (regardless of whether or not the application has focus/is visible) then you need to use pinvoke to hit the win32 apis. I suggest you read the following:
link text
Please let us know what you are trying to do so we can provide better feedback.
Using Google, I found this Keyhook example.
I've worked with keyhooks before, in Delphi WIN32, so I am a bit familiar with them. (Just not in C#.) If you add one to a DLL, all Hell might break loose since most virus scanners will recognise this as malware behaviour. (Especially if you use them in the wrong way, causing them to be injected in each and every process that's running on your system.)
A keyhook will allow key combinations to be captured from other processes, though.
For a solution without programming requirements: Drop a shortcut for the application on your desktop. Edit it, assign a shortcut, close it. Press shortcut to test...