Max length for an Int field not working?

Mitch Moses
Giga Expert

find_real_file.png

 

find_real_file.png

1 ACCEPTED SOLUTION

I think its a bug in SN. If you have HI account, post a request there and they should help you.

Regarding the fix, you can use client script.

Write a onchange client script on your Bridge meeting field like below

function onChange(control, oldValue, newValue, isLoading, isTemplate) {
   if (isLoading || newValue === '') {
      return;
   }
	if(newValue.length>1) {
		g_form.showErrorBox("u_bridge_meeting","You cannot enter more than 1 digit",true);
	}
}

Mark the comment as a correct answer and also helpful once worked.

View solution in original post

9 REPLIES 9

It works.Javascript converts it implicitly. Already checked in my dev instance before sharing the code.

Abhinay Erra
Giga Sage

You can use on change client script for that and validate number of digits entered.

Abhinay Erra
Giga Sage

Replace comma before checking the length.

g_form.getValue("u_bridge_meeting").replace(/,/g,'').length;

Hi Mitch

It might not require as you are only checking for a length of 1. The comma gets added only after 3 digits. 

Please mark my comment as a correct answer and also helpful once worked.

Priti Golam1
Tera Expert

Hi Mitch,

    You can refer the below link, In this link this is specially mention that 

  • You can only change this value for a String field. Changes for any other type of field are ignored.

 https://old.wiki/index.php/System_Dictionary

For your refrence i have attached one image kindly go through it.

If you found my answer helpful kindly mark it as helpful or correct

Thanks and Regards,

 Priti Golam