JNJayaleshwari N Syncfusion Team February 12, 2019 07:53 AM
We have checked your query regarding StringLengthAttribute.MaximumLength property in SfDatForm Xamarin Forms. According to DataForm, StringLength.MaximumLength property is used for validating the editor value. String type property can be validated using this attribute.
You can refer our online user guide documentation link below.
Please let us know whether the provided solution satisfies your requirement. If not, kindly revert us back with more details related to your requirement with screenshots (if possible). It will be helpful for us to provide you possible solution.
CMChris MarinacciFebruary 12, 2019 11:32 AM
I was expecting that StringLengthAttribute would work the same way that it does in ASP.NET -- the input field associated with the property that has the StringLengthAttribute does not allow the user to physically type more characters into the field than the value of StringLengthAttribute.MaximumLength. This is in addition to its use in validation.
SGSwathi Gopal Syncfusion Team February 13, 2019 07:37 AM
Currently we are analyzing your query related to restrict to type the characters into the editor field when exceeded than the value of StringLengthAttribute.MaximumLength property in SfDataForm Xamarin Forms. We will analyze and update you the details in two business days (Feb 15,2019). We appreciate your patience until then.
Regards, Swathi G
JNJayaleshwari N Syncfusion Team February 15, 2019 04:01 AM
As mentioned in our earlier updates, in DataForm, StringLength.MaximumLength property is used for validating the editor value. String type property can be validated using this attribute. However, your requirement to restrict the user to physically type more characters into the entry field can be achieved using DataFormTextEditor in dataform. Entry is loaded in DataFormTextEditor and its properties (like MaxLength) can be accessed in the override methods of the DataForm text editor.
We have created a sample for the same. In the sample used DataFormTextEditor and restricted the characters in entry using MaxLength property of entry for the FirstName data field in the dataform. You can download the same from the following location.