每当我将对象插入此数据网格时,它都会显示此错误
TypeError:错误 #1009:无法访问空对象引用的属性或方法。在 Forms::LessonPlan/addLesson_clickHandler()
这是我插入对象的代码
var obj:Object = new Object();
var temp:Object = new Object();
obj.activityid = arrayNames.selectedItem.activityid;
obj.lessonid = getLessonIDResult.lastResult ;
obj.time = durationCombo.selectedItem;
obj.status = "active";
obj.activityname = arrayNames.selectedItem.activityname;
temp = ({activityname:obj.activityname,time:obj.time});
studentLessonPlanArray.addItem(temp);
请帮我