flex-users / flexlib

Open Source Flex components library.
github.com/flex-users/flexlib
MIT License
205 stars 88 forks source link

null reference to working object TreeGrid #44

Open nicoulaj opened 13 years ago

nicoulaj commented 13 years ago

Originally filed by Porcupin...@gmail.com on 2007-07-11T21:30:56

I'm having a strange error. I define a treegrid object name tableDisplay3, the object works, displays data, collapses and uncollapses just fine. But tableDisplay3 is a null reference. I don't understand how the program can fully load the object, and tableDisplay3 can still be a null reference. Can someone help? thanks.

Here's the code where I declare the TreeGrid

<flexlib:TreeGrid id="tableDisplay3" width="100%" height="100%" dataProvider="{ dataObj }" paddingLeft="25" verticalTrunks="normal" rowHeight="30" showRoot="false" disclosureClosedIcon="@Embed(source='tree_openNode.png')" disclosureOpenIcon="@Embed(source='tree_closeNode.png')" folderClosedIcon="@Embed(source='status.png')" folderOpenIcon="@Embed(source='status.png')" iconField="@Embed(source='status.png'" > flexlib:columns

    <mx:DataGridColumn dataField="desc" />
/flexlib:columns

/flexlib:TreeGrid

This is the error I get after running Alert.show(String(tableDisplay3.id))

TypeError: Error #1009: Cannot access a property or method of a null object reference. at helper/__panel1_creationComplete() at flash.events::EventDispatcher/flash.events:EventDispatcher::dispatchEventFunction() at flash.events::EventDispatcher/dispatchEvent() at mx.core::UIComponent/dispatchEvent() at mx.core::UIComponent/set initialized() at mx.managers::LayoutManager/private::doPhasedInstantiation() at Function/http://adobe.com/AS3/2006/builtin::apply() at mx.core::UIComponent/private::callLaterDispatcher2() at mx.core::UIComponent/private::callLaterDispatcher() at [enterFrameEvent]

What is the expected output? What do you see instead? Expect to see "tableDisplay3", get error message as stated above.

What version of the product are you using? On what operating system? flex 3.0 build 173069, using flexlib 1.9

Please provide any additional information below.

nicoulaj commented 13 years ago

Updated by dmcc...@gmail.com on 2007-09-09T01:44:59

Added label TreeGrid

nicoulaj commented 13 years ago

Updated by dmcc...@gmail.com on 2007-12-26T19:29:52

Removed label TreeGrid Added label FlexLib-TreeGrid