|
系统调试出现如下问题,请问怎么改?谢谢
TypeError: Error #1009: 无法访问空对象引用的属性或方法。
at main/AddLogItem()[C:\Documents and Settings\Administrator\桌面\10\10-25\src\main.mxml:31]
at main/___main_Button1_click()[C:\Documents and Settings\Administrator\桌面\10\10-25\src\main.mxml:65]
源代码提示出错的地方:
private function AddLogItem():void
{
var log:Array = new Array(txtTitle.text, dcLogDate.selectedDate.toDateString(), txtContent.text);
// 增加到数组集合中
arrLogs.addItem(log);
<mx:Button x="248" y="168" label="保存" fontSize="12" click="AddLogItem()"/> |
|