In a classic textformfield widget, I want to put the "/" character automatically after the fourth character when the user enters input. How can I do this?
Thanks for help!
Example input 2012/324234
OcasTextFormFieldContent(
maxLength: 12,
inputType: TextInputType.number,
validator: (String? fieldContent) {
if (fieldContent == "" || fieldContent == null) {
return 'not empty';
} else if (fieldContent.length < 12) {
return 'wrong type.';
} else {
return null;
}
},
controller: _dosyaNo,
name: "Doc No: ",
placeholder: "Please enter doc no"),