Note that there are some explanatory texts on larger screens.

plurals
  1. POWhen I change a property name in a custom component, the flash compiler throws a ReferenceError
    primarykey
    data
    text
    <p>I'm building a custom Datagrid component, and I had three parameter properties: </p> <pre><code>[Collection] _columns [Inspectable] _headerHeight [Inspectable] _rowHeight </code></pre> <p>This all compiled fine, but I needed to change things about the <code>_columns</code> variable, and it made sense to instead create <code>_columnData</code> to store data from a <code>DataProvider</code>. </p> <p>Now it throws a <code>ReferenceError</code> every time I try to <em>Test Movie</em>, saying that the property <code>columnData</code> can't be created, despite listing it in the parameter list in the Flash Professional IDE.</p> <p>The only thing I can imagine is that Flash is somehow caching an earlier version of my class, but that the Flash IDE is correctly updating itself according to my metadata when I rebuild the component. I've cleared out all the stuff from <code>~/Library/Application Support/Adobe/Flash CS5/CodeModel</code>, restarted Flash, deleted ASO files, I've moved all the files to a new machine, and even built the component from scratch (using the same class) in a new FLA - nothing has worked.</p> <p>The code causing errors is copied below:</p> <pre><code>private var _columnData:Object; private var _headerHeight:Number = 40; private var _rowHeight:Number = 40; [Collection(collectionClass="musicone.components.data.DataCollection", collectionItem="musicone.components.controls.datagrid.DatagridColumn", identifier="item")] public function get columnData():Object { return _columnData; } public function set columnData(value:Object):void { _columnData = value; var _forceClass:DataCollection = value as DataCollection; //updateColumns(); draw(); } [Inspectable(type="Number", defaultValue=40)] public function get headerHeight():Number { return _headerHeight; } public function set headerHeight(value:Number):void { _headerHeight = value; draw(); } [Inspectable(type="Number", defaultValue=40)] public function get rowHeight():Number { return _rowHeight; } public function set rowHeight(value:Number):void { _rowHeight = value; draw(); } </code></pre> <p>EDIT: One of the main reasons I'm thinking my code is getting cached somewhere is that changes in the draw() function aren't being shown anywhere - in other words, the only place I can guarantee my changes are having an effect is in the Flash IDE. That said, the fact that the same error occurs on a different machine leads me to believe it's something intrinsic...</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload