eduardosuruagy Posted June 27, 2019 Share Posted June 27, 2019 do you have to remove accentuated letter-typing from the client side? Link to comment Share on other sites More sharing options...
Sherzod Posted June 28, 2019 Share Posted June 28, 2019 5 hours ago, eduardosuruagy said: do you have to remove accentuated letter-typing from the client side? Sorry, can you please clarify your question? Link to comment Share on other sites More sharing options...
eduardosuruagy Posted June 28, 2019 Author Share Posted June 28, 2019 2 hours ago, Sherzod said: Desculpe, você pode por favor esclarecer sua pergunta? In my record screens I would like to restrict the accented letters in the Edits fields, type these letters á, é, í, ... How can I do this on the client side? On the server side I get it, but I think it's faster on the client side. Link to comment Share on other sites More sharing options...
belo Posted June 28, 2019 Share Posted June 28, 2019 function keypress(sender, e, eOpts) { // [\u0300-\u036f]/g this code snippet is a regular expression // that takes the range of accents: ', ~, ^ function removerAcentos(s) { return s.normalize('NFD').replace(/[\u0300-\u036f]/g, "") } var val = sender.getValue() ; sender.setValue(removerAcentos(val)); } best regards Eduardo Belo Link to comment Share on other sites More sharing options...
eduardosuruagy Posted July 1, 2019 Author Share Posted July 1, 2019 On 6/28/2019 at 2:05 AM, belo said: function keypress(sender, e, eOpts) { // [\u0300-\u036f]/g this code snippet is a regular expression // that takes the range of accents: ', ~, ^ function removerAcentos(s) { return s.normalize('NFD').replace(/[\u0300-\u036f]/g, "") } var val = sender.getValue() ; sender.setValue(removerAcentos(val)); } best regards Eduardo Belo Muito obrigado Eduardo, funcionou!!! Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now