var
dj:integer;
djx:string;dj:= int(strtofloat(djx) * 10000) // 运行到此处提示 Incompatible types: 'Integer' and 'Extended' 是何原因
dj:integer;
djx:string;dj:= int(strtofloat(djx) * 10000) // 运行到此处提示 Incompatible types: 'Integer' and 'Extended' 是何原因
你的dj是一个整型,而你运算的表达式是一个浮点数,两者类型不兼容。如果用下式就可以了:
dj := trunc(StrToFloat(djx)*1000);
类似这样的 Incompatible types: 'XXX' and 'XXX'
都是类型不匹配了