如何验证是否从列表中选择了至少一个项目,以便在应用程序的init()处将 selectedIndices 设置为NULL?
答案 0 :(得分:1)
以下代码可以帮助想要验证我想要的列表的人:
<mx:NumberValidator
id ="myListValidator"
trigger ="{myButton}"
triggerEvent ="click"
minValue ="0"
lowerThanMinError="Should I write an application to you for selecting atleast one of the option X-("
source ="{myList}"
property ="selectedIndex"
/>