# Pop Up keyboard in for system.gui.password input

**URL:** <https://forum.inductiveautomation.com/t/pop-up-keyboard-in-for-system-gui-password-input/42028>\
**Category:** Ignition\
**Created:** [January 7, 2021, 3:08pm UTC](https://forum.inductiveautomation.com/t/pop-up-keyboard-in-for-system-gui-password-input/42028 "2021-01-07T15:08:37Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![hrissley](https://avatars.discourse-cdn.com/v4/letter/h/e79b87/32.png) [@hrissley](https://forum.inductiveautomation.com/u/hrissley)\
**Post date:** [January 7, 2021, 3:08pm UTC](https://forum.inductiveautomation.com/t/pop-up-keyboard-in-for-system-gui-password-input/42028/1 "2021-01-07T15:08:37Z")

</div>

New to Ignition, have a password box popup with

tagValue = True  
password = system.gui.passwordBox(“Please enter the password.”)  
if password == “1234”:  
system.nav.openWindow(“Release”)  
else:  
system.gui.errorBox(“Incorrect password”)

would like to have onscreen keyboard popup, I do have touchscreen enabled, what should I do?

---

<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:** [January 7, 2021, 5:36pm UTC](https://forum.inductiveautomation.com/t/pop-up-keyboard-in-for-system-gui-password-input/42028/2 "2021-01-07T17:36:00Z")

</div>

Instead of system.gui.passwordBox, try [https://docs.inductiveautomation.com/display/DOC81/system.gui.showTouchscreenKeyboard](https://docs.inductiveautomation.com/display/DOC81/system.gui.showTouchscreenKeyboard), with the passwordMode parameter.

---

<div class="post-metadata">

**Author:** ![gilles.levesque](https://avatars.discourse-cdn.com/v4/letter/g/919ad9/32.png) [@gilles.levesque](https://forum.inductiveautomation.com/u/gilles.levesque)\
**Post date:** [February 11, 2022, 4:01pm UTC](https://forum.inductiveautomation.com/t/pop-up-keyboard-in-for-system-gui-password-input/42028/3 "2022-02-11T16:01:25Z")

</div>

I had the same problem, and i’ve tried to use system.gui.shotTouchscreenKeyboard and i set the passwordMode to true or 1, to hide the text entered, but it’s still showing the password text on the push button.

Here is my Scrip:

```nohighlight
	password = event.source.text = system.gui.showTouchscreenKeyboard("Modification Paramêtres",20,True)
	if password == event.source.Password:
    		system.tag.write('CLX_PLASTIQUE/EditEnable', 1)
if event.source.EditEnable== 1:
    system.tag.write('CLX_PLASTIQUE/EditEnable', 0) 

```

It’s a toggle Push Button to enable or disable the editable properties of few fields

---

<div class="post-metadata">

**Author:** ![kcollins](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kcollins/32/19646_2.png) [@kcollins](https://forum.inductiveautomation.com/u/kcollins)\
**Post date:** [February 11, 2022, 4:11pm UTC](https://forum.inductiveautomation.com/t/pop-up-keyboard-in-for-system-gui-password-input/42028/4 "2022-02-11T16:11:02Z")

</div>

Can you edit your script to place the contents inside of a code block, like below:

![code block](https://us1.discourse-cdn.com/inductiveautomation/original/3X/0/0/00faa1e6aaf4ded5a6b5f0ecde5e94339aa25bd0.gif)

You can create (and terminate) the code block with three backticks. It makes it a lot easier to read (and currently, it looks like there is a syntax error, but might just be formatting).

---

<div class="post-metadata">

**Author:** ![gilles.levesque](https://avatars.discourse-cdn.com/v4/letter/g/919ad9/32.png) [@gilles.levesque](https://forum.inductiveautomation.com/u/gilles.levesque)\
**Post date:** [February 11, 2022, 5:03pm UTC](https://forum.inductiveautomation.com/t/pop-up-keyboard-in-for-system-gui-password-input/42028/5 "2022-02-11T17:03:37Z")

</div>

I have found an acceptable solution,

```nohighlight
	password = event.source.text = system.gui.showTouchscreenKeyboard("<Html><center>Modification<br>Paramêtres",20,True)
	if password == event.source.Password:
    		system.tag.write('CLX_PLASTIQUE/EditEnable', 1)
    		event.source.text = "<Html><center>Modification<br>Parametres"
if event.source.EditEnable== 1:
    system.tag.write('CLX_PLASTIQUE/EditEnable', 0)

```

I am writing back on the push button text the original text of the push button…  
Only problem is it does not translate well the frebch accents, Parameter in french is writed Paramètres  
If i add the accent in the script i get weird characters ParamÀ`tres.

---

<div class="post-metadata">

**Author:** ![kcollins](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/kcollins/32/19646_2.png) [@kcollins](https://forum.inductiveautomation.com/u/kcollins)\
**Post date:** [February 11, 2022, 5:08pm UTC](https://forum.inductiveautomation.com/t/pop-up-keyboard-in-for-system-gui-password-input/42028/6 "2022-02-11T17:08:35Z")

</div>

This line is causing you troubles:

```auto
password = event.source.text = system.gui.showTouchscreenKeyboard("Modification Paramêtres",20,True)

```

You’re trying to assign a variable `password` to the result of an assignment of `system.gui.showTouchscreenKeyboard()` to `event.source.text` (which is what places the password text on your button).

I’d suggest something like this instead:

```auto
password = system.gui.showTouchscreenKeyboard("Modification Paramêtres",20,True)
if password == ...

```

See this example in regular python to see why you’re getting this behavior:  
 ![2022-02-11 at 11.09 AM](https://us1.discourse-cdn.com/inductiveautomation/original/3X/6/8/68f26e8932291504245359c7ed70deb426eb597f.png)

Both `a` and `b` are assigned the value “c”

---

<div class="post-metadata">

**Author:** ![gilles.levesque](https://avatars.discourse-cdn.com/v4/letter/g/919ad9/32.png) [@gilles.levesque](https://forum.inductiveautomation.com/u/gilles.levesque)\
**Post date:** [February 11, 2022, 6:19pm UTC](https://forum.inductiveautomation.com/t/pop-up-keyboard-in-for-system-gui-password-input/42028/7 "2022-02-11T18:19:30Z")

</div>

Yes it worked perfectly…
