'How to use Event keycode in PDF Form using Javascript

I am trying not to use backspace and delete button in a text box in PDF form by using JavaScript. But the following code is not working.

 if(event.keyCode == 8 || event.keyCode == 46){
         app.alert("alert box");
 }
 event.rc = false;

Any solutions for this



Solution 1:[1]

Maybe this expression will work

import re

t='mailto:[email protected]'
re.findall('mailto:(?:\w+\.?)+@(?:\w+\.?)+',t)

['mailto:[email protected]']

RegExp test

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 arutar