从 TextInput 扩展组件时 Flex MXML 错误
这个 Flex MXML 代码有什么问题吗?我收到错误消息(标有“X”的错误行)。代码很简单,但我找不到错误。
两次消息:“字符串”类型的标准属性“文本”的多个初始化值(从德语翻译)
<?xml version="1.0" encoding="utf-8"?>
<s:TextInput xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
focusIn="keyboardIsOpen=true"
X focusOut="keyboardIsOpen=false">
<fx:Script>
<![CDATA[
//var
static public var keyboardIsOpen:Boolean = false;
]]>
X </fx:Script>
</s:TextInput>
Whats wrong with this Flex MXML code? I'm getting error messages (error lines marked with "X"). Code is very simple but I cannot find the error.
Message both times: multiple initalisation values for standard property "text" of type "string" (translated from german)
<?xml version="1.0" encoding="utf-8"?>
<s:TextInput xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
focusIn="keyboardIsOpen=true"
X focusOut="keyboardIsOpen=false">
<fx:Script>
<![CDATA[
//var
static public var keyboardIsOpen:Boolean = false;
]]>
X </fx:Script>
</s:TextInput>
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
这是 Flex SDK 的问题。 Bug - 25184 根据错误报告中的注释,解决方法是显式设置像这样的文本属性。
This is an issue with the Flex SDK. Bug - 25184 The workaround according to the comments in the bug report is to explicitly set the text property like this.
我刚刚解决了你的问题。
我最初发现错误
然后错误显示为“此行有多个标记:
-焦点输出
-默认属性“文本”的多个初始值设定项值,类型为“字符串””
我刚刚更改了代码,添加了一个黑白属性
I ve just solve your problem.
I found error initially
then error showing is "Multiple markers at this line:
-focusOut
-Multiple initializer values for default property, 'text', of type 'String'"
I ve just change code, a property added b/w these