它用于int解析。
如果一个人使用,则会出现异常
try StrToInt(s); except //exception handling end;
var s: String; iValue,iCode: Integer; ... val(s,iValue,iCode); if iCode = 0 then ShowMessage('s has a number') else ShowMessage('s has not a number');