How to stop user should not able to enter nth character
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-20-2023 01:22 AM
Hi all,
In single text variable if user trying to enter 11th character, it should not allow to enter 11th character.
Ex:
1) Assume that Single line text variable name is "please enter your bank name"
2)Consider bank name should be 10 characters only.
3)if user trying to add 11th character it should not allow and give error like "the bank name should not be more than 10 characters."
4) please help me how to restrict users from to not entering 11th character.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-20-2023 01:26 AM
Hi,
Put max_length=10 in variable attributes
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-20-2023 02:03 AM
Hi Shruti,
thanks for your response.
there is small change in my requirement, please tell me how to do it.
Ex:
1) Assume that Single line text variable name is "please enter your bank names" and total length of the variable is 21 characters including comma(,).
2)User need to enter two bank names and each bank name should be having <=10 characters only.
3)if user entered 1st bank name <= 10, it should allow. if 1st bank name having more than 10 characters it should not allow 11th character
3) Similarly, the user entered the 2nd bank name with comma, if user entered 2nd bank name <= 10, it should allow. if 2nd bank name having more than 10 characters it should not allow 11th character
4)if user trying to add 11th character it should not allow and give error like "the bank name should not be more than 10 characters."
4) please help me how to restrict users from to not entering 11th character.