How to use length function in aras?server side method.

//code to validatde item_number should not be more than 20 characters. Innovator inn=this.getInnovator(); Item itmid=this.getProperty("item_number"); //return this.getInnovator().newError("hello"); if(itmid.Length == 20) { return this.getInnovator().newError("Invalid Value!"); }