cyracks Posted January 11 Share Posted January 11 Hello. On mobile keyboard shown for TUniFormattedNumberEdit is not numeric, but alphanumeric. I have tried every tip on the forum but can not make it show numeric keyboard. None of the options bellow work. (FrameEditNumQty.NumberEdit as IUniJSInterface).JSConfig('inputType',['number']); // this brakes the whole program FrameEditNumQty.NumberEdit.JSInterface.JSConfig('inputType',['number']); FrameEditNumQty.NumberEdit.JSInterface.JSCall('inputEl.dom.setAttribute', ['display', 'number']); with FrameEditNumQty.NumberEdit, JSInterface do begin JSAssign('inputEl.dom.type', ['number']); end; I am using Version:1.90.0 build 1551. Alternative would be to use TUniEdit with input type Number, but in this case I do not know how to show decimal separator as , it is always . (I would actually prefer TUniEdit instead of TUniFormattedNumberEdit) Thank you for the help. Quote Link to comment Share on other sites More sharing options...
Sherzod Posted January 11 Share Posted January 11 Hello, Please clarify again, as I understand it, you are using a desktop application that opens on a mobile device? And what numbers, format do you want to use? And what problem are you facing? Quote Link to comment Share on other sites More sharing options...
cyracks Posted January 11 Author Share Posted January 11 I am using desktop version of Unigui also in mobile application (I decided to use desktop version in mobile environment after comparing both and decided that mobile is not ok - I forget all the reasons but one of them was no gridview component and dbgrid did not have option ForceFit). Desktop is ok also on mobile but there are some problems like inputtype for TUniFormattedNumberEdit. If you add uniedit and set inputtype to number everything is ok (keyboard is numeric), but decimal separator is . instead of , (do not know how to change that I tried a couple of options nothing worked). So I tried to use TUniFormattedNumberEdit, where decimal separator can be changed (there is also a thousand separator which is a bonus), but when used on mobile wrong keyboard is show. So the solution to my problem is either: - change decimal separator (from . to ,) in unidit if inputtype is number or - on mobile show numeric keyboard when using TUniFormattedNumberEdit. Or put it another way, I would like to configure the following on one component: - decimal separator - keyboard that is show on mobile Quote Link to comment Share on other sites More sharing options...
cyracks Posted January 12 Author Share Posted January 12 On the link above it is written that decimal separator for uniedit can be changed in ExtEvents function OnBeforeRender, but it does not work form me. function OnBeforerender(sender) { sender.maskRe=/[+\-\,0-9]/ } Is there really no way to change decimal separator in Uniedit if input type is number ? Quote Link to comment Share on other sites More sharing options...
Oliver Morsch Posted January 14 Share Posted January 14 Which device and keyboard do you use? Is the number keyboard correctly shown in mobile demo? Quote Link to comment Share on other sites More sharing options...
cyracks Posted January 14 Author Share Posted January 14 Any mobile device and no TUniFormattedNumberEdit does not show correct keyboard if I run demo \Demos\Desktop\FormattedEdit on mobile device This is by default This is how it looks if I manually change keyboard setting on mobile device that numbers are always shown Quote Link to comment Share on other sites More sharing options...
Oliver Morsch Posted January 14 Share Posted January 14 Is it correctly shown on mobile demo? Quote Link to comment Share on other sites More sharing options...
cyracks Posted January 14 Author Share Posted January 14 I did not try on mobile demo, probably yes. I am having trouble with input-type of desktop component TUniFormattedNumberEdit on mobile device. I know that mobile controls are more designed for mobile devices, but I am not asking for something to specific, just how to show the right type of keyboard. Quote Link to comment Share on other sites More sharing options...
Oliver Morsch Posted January 14 Share Posted January 14 Then try mobile demo and when this works you can look in browser developer tools which properties this edit control has. Quote Link to comment Share on other sites More sharing options...
zanona Posted March 21 Share Posted March 21 Em 14/01/2024 às 11:03, cyracks disse: Eu não tentei na demonstração móvel, provavelmente sim. Estou tendo problemas com o tipo de entrada do componente de desktop TUniFormattedNumberEdit no dispositivo móvel. Eu sei que os controles móveis são mais projetados para dispositivos móveis, mas não estou pedindo algo específico, apenas como mostrar o tipo certo de teclado. Você encontrou uma solução para o seu caso usando formattedNumberEdit ? Quote Link to comment Share on other sites More sharing options...
cyracks Posted March 21 Author Share Posted March 21 No I did not. Please post the solution if you find it. Quote Link to comment Share on other sites More sharing options...
zanona Posted March 21 Share Posted March 21 24 minutes ago, cyracks said: Não, eu não fiz. Por favor, poste a solução se você encontrá-lo. Not solution! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.