0

如何在 flex 中提醒整数值。我有一个名为 total 的变量,它是一个整数。

如果我尝试使用

var total:int=myTest.length;
Alert.show(total);

它抛出一个错误说

1067: Implicit coercion of a value of type int to an unrelated type String.

show 方法只接受字符串值。如何提醒这个 int 值?

实际上,我想要知道存储在总变量中的值。

4

1 回答 1

3
Alert.show(total.toString());

参考

于 2009-10-20T11:53:47.583 回答