Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to change the active element on the form.
#11
You can try something like this in your IWedit OnHTMLtag for numeric keyboard in Mobile:
Code:
procedure TIWF_Menu.IWEdit1HTMLTag(ASender: TObject; ATag: TIWHTMLTag);
begin
   ATag.AddStringParam('inputmode', 'decimal');
   ATag.AddStringParam('pattern', '[0-9]*');
   ATag.AddStringParam('autocorrect', 'off');
end;
No tested, but I think if you correct define DataType = stTel or DataType = stEmail, etc, mobile keyboard showed based on DataType you choose.
Reply
#12
I'm sorry, I didn't understand where to set the DataType = stTel type ... There is no such property in TIWEdit...

procedure TIWF_Menu.IWEdit1HTMLTag(ASender: TObject; ATag: TIWHTMLTag);
begin
ATag.AddStringParam('inputmode', 'decimal');
ATag.AddStringParam('pattern', '[0-9]*');
ATag.AddStringParam('autocorrect', 'off');
end;
It works!

But what if this option is used for input:
Mess := 'Enter the PIN code to log in (numbers only)';
WebApplication.ShowPrompt(mMess, 'ClbPinWork', 'Authorization',", 'Ok', 'Forgot PIN');
Reply
#13
IIRC there was a demo showing how to handle TAB as ENTER. I'll have a look and get back to you. Maybe we can introduce something to help you with this case... let's see.

Regarding smartphone, this is another completely different subject, unfortunately.
Some phones have the tab key (e.g. some Samsung models), some don't (my Android phone doesn't have it)... so it is completely unreliable. Seems that companies expect smartphone users to handle the navigation in a point/touch way, instead of using the keyboard.
Reply
#14
(07-28-2021, 06:02 PM)Сергей Александрович Wrote: I'm sorry, I didn't understand where to set the DataType = stTel type ... There is no such property in TIWEdit...

procedure TIWF_Menu.IWEdit1HTMLTag(ASender: TObject; ATag: TIWHTMLTag);
begin
  ATag.AddStringParam('inputmode', 'decimal');
  ATag.AddStringParam('pattern', '[0-9]*');
  ATag.AddStringParam('autocorrect', 'off');
end;
It works!

But what if this option is used for input:
Mess := 'Enter the PIN code to log in (numbers only)';
WebApplication.ShowPrompt(mMess, 'ClbPinWork', 'Authorization',", 'Ok', 'Forgot PIN');

There is, in newer IW 15. What's the version you have installed?
Reply
#15
IntraWeb Version: 15.1.10
Reply
#16
Install the latest version of IW. I see that there is another parameter in ShowPrompt. How to specify it?

WebApplication.ShowPrompt(mMess, 'ClbPinWork', 'Authorization',", 'Ok', 'Forget PIN', ?????????);
Reply
#17
It is optional. The default is nil. If your code was working before without it, leave it as is.
Reply
#18
(08-08-2021, 07:31 AM)Александр Мачадо Wrote: It is optional. The default is nil. If your code was working before without it, leave it as is.

I need to control the display mode of the virtual keyboard. What parameters do I need to set to display the keyboard in digital input mode? What parameters are generally possible?
Reply
#19
I guess you mean this?

"I need to control the display mode of the virtual keyboard. What options do I need to set to display the keyboard in numeric input mode? What parameters are generally possible?"

Please post your questions in English. You can use Google Translator (as I did) and it will be good enough.

Regargind numeric keyboard for mobile, IWEdit if you set DataType = stNumber, mobile browsers will automatically display the numeric keyboard. There are also other options for other data types
Reply
#20
Alexander, thank you for your answer. The translator I use lets me down... I insert the text in the response in English (already ready to send), and the translator translates it into Russian again... Now I will closely monitor this...

DataType = stNumber, - Great!

What other types are possible?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)