JSFiddle - React, Tailwind, and code Playground
HTML
<input name="aendcodeM" id="aendcodeM" type="text" size="25" onKeyPress="return numchar(event)" onKeyup="autotab(this, document.form1.bendcodeM)"/>
<input name="bendcodeM" id="bendcodeM" type="text" size="25" onKeyPress="return numchar(event)" onKeyup="autotab(this, document.form1.bndwdM)"/>
JavaScript
$(document).ready(function() {
$("input, textarea").keyup(function() {
var val = $(this).val()
$(this).val(val.toUpperCase());
});
$('input[type="text"]').on('keypress', function() {
var $this = $(this), value = $this.val();
if (value.length === 1) {
$this.val( value.charAt(0).toUpperCase() );
}
});
})