# Error 1009 Problem with yahoo components

**URL:** <https://forum.kirupa.com/t/error-1009-problem-with-yahoo-components/285214>\
**Category:** flash\
**Created:** [March 28, 2009, 6:45pm UTC](https://forum.kirupa.com/t/error-1009-problem-with-yahoo-components/285214 "2009-03-28T18:45:07Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![rondog](https://yyz1.discourse-cdn.com/flex011/user_avatar/forum.kirupa.com/rondog/32/2478_2.png) [@rondog](https://forum.kirupa.com/u/rondog)\
**Post date:** [March 28, 2009, 6:45pm UTC](https://forum.kirupa.com/t/error-1009-problem-with-yahoo-components/285214/1 "2009-03-28T18:45:07Z")

</div>

I am using the Yahoo ASTRA menu bar. I have two dataProviders:

```auto

var initialMenu:XML = 
<menus>
<menu label="File ">
	<menuitem label="New Client" />
	<menuitem label="New Admin" />
	<menuitem label="Close" />
</menu>
</menus>;

var clientSelectedMenu:XML = 
<menus>
<menu label="File ">
	<menuitem label="New Project" />
	<menuitem label="Close Client" />
	<menuitem label="Close" />
</menu>
</menus>;

```

When I open a client I change my dataProvider to ‘clientSelectedMenu’ and it works fine. When I select “Close Client” I set my dataProvider back to ‘initialMenu’

and I get this error:

```auto

TypeError: Error #1009: Cannot access a property or method of a null object reference.
	at com.yahoo.astra.fl.controls::Menu/hide()
	at com.yahoo.astra.fl.controls::Menu/com.yahoo.astra.fl.controls:Menu::hideAllMenus()
	at com.yahoo.astra.fl.controls::Menu/com.yahoo.astra.fl.controls:Menu::handleCellRendererClick()

```

The funny thing is, the menu still works the way it should and has the correct menu items in it. It just keeps throwing that error after I set the dataProvider the third time.
