# Programmatically close mobile keyboard from scripting

**URL:** <https://forum.inductiveautomation.com/t/programmatically-close-mobile-keyboard-from-scripting/11926>\
**Category:** Ignition\
**Created:** [July 13, 2016, 2:23pm UTC](https://forum.inductiveautomation.com/t/programmatically-close-mobile-keyboard-from-scripting/11926 "2016-07-13T14:23:43Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![mikehill100](https://avatars.discourse-cdn.com/v4/letter/m/bcef8e/32.png) [@mikehill100](https://forum.inductiveautomation.com/u/mikehill100)\
**Post date:** [July 13, 2016, 2:23pm UTC](https://forum.inductiveautomation.com/t/programmatically-close-mobile-keyboard-from-scripting/11926/1 "2016-07-13T14:23:43Z")

</div>

Hi everyone,

Saw one topic on it, but he didn’t find a good solution. Is there any way to close a mobile keyboard from scripting?

Thanks!

- Mike

---

<div class="post-metadata">

**Author:** ![mikehill100](https://avatars.discourse-cdn.com/v4/letter/m/bcef8e/32.png) [@mikehill100](https://forum.inductiveautomation.com/u/mikehill100)\
**Post date:** [July 14, 2016, 3:23pm UTC](https://forum.inductiveautomation.com/t/programmatically-close-mobile-keyboard-from-scripting/11926/2 "2016-07-14T15:23:49Z")

</div>

Does anyone know if this is possible?

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [July 15, 2016, 5:00pm UTC](https://forum.inductiveautomation.com/t/programmatically-close-mobile-keyboard-from-scripting/11926/3 "2016-07-15T17:00:00Z")

</div>

This is not officially supported, but the following works through Swing:

`
touchtype = "<type 'com.inductiveautomation.factorypmi.application.components.touchscreen.JDialogPopupWindowParent'>"
from javax.swing import JWindow
for win in JWindow.getWindows():
	if str(win.getClass()) == touchtype:
		win.dispose()`

Edit 10/24/16:  
If anyone searches for this in the future, I’d recommend the following over the above code:

[code]from com.inductiveautomation.factorypmi.application.components.touchscreen import JDialogPopupWindowParent  
from javax.swing import JWindow

for win in JWindow.getWindows():  
if isinstance(win, JDialogPopupWindowParent):  
win.dispose()[/code]

It doesn’t rely on hokey type-casting to check for the mobile keyboard.
