I have set up this type of itemorder package:
PackageMerenders {import mx.controls. AdvancedDataGridClassesEasibleDataGrid itamenderer;
Public class header reader provides the Advanced Data Grid Eaterser {public function theHeaderRenderer () {super (); SetStyle ("verticalAlign", "Medium"); }} }
However, when I include the following lines in my advanced data grid column tag,
& lt; Fx: Component & gt; & Lt; Myrenderers: theHeaderRenderer "/> & Lt; fx: Component & gt; & lt; renderers: someotherrenderer /> & lt; / fx: component & gt; & lt; / mx: itemRenderer & gt; the following error:
TypeError: error # 1034: type statement failed: mx.controls.dataGridClasses :: mx.controls.advancedDataGrid classes. Advensdetagrit Listdeta from DataGridListData @ ac84f81. Mx.controls Can not be changed on .advancedDataGridClasses: AdvancedDataGridItemRenderer / set listData () [E: \ dev \ 4.x \ Frameworks \ Projects \ DataVigilation \ src \ MX \ n Restriction \ Unntdetagrid Classes \ Unntdetagrid Itamrender.as: 232] on Makskantrol :: Datagrid / http: //www.adobe.com/2006/flex/mx/intern:: HeaderHeight () [E: \ dev \ 4.x \ frameworks \ projects \ framework \ src \ mx \ controls \ DataGrid.as: 2182] on mx.controls.dataGridClasses :: DataGridHeader / measure () [E: \ dev \ 4.x \ frameworks \ projects \ framework \ src \ mx \ controls \ dataGridClasses \ DataGridHeader.as: 201] m X.core :: UIComponent / measureSizes () [E: \ dev \ 4.x \ frameworks \ projects \ framework \ src \ mx \ core \ UIComponent.as: 8216 ] At mx.core: UIComponent / validateSize () [E: \ dev \ 4.x \ frameworks \ projects \ framework \ src \ mx \ core \ UIComponent.as: 8140] And mx.managers :: LayoutManager / validateSize () [E: \ dev \ 4.x \ frameworks \ projects \ framework \ src \ mx \ managers \ LayoutManager.as: 617] mx.managers on :: LayoutManager / doPhasedInstantiation () [e: \ dev \ 4.x \ frameworks \ projects \ framework \ src \ mx \ managers \ LayoutManager .as: 709] mx.managers :: LayoutManager / doPhasedInstantiation callback () [e: \ dev \ 4.x \ frameworks \ Projects \ Framework \ src \ mx \ managers \ LayoutManager.as: 1072] How can you come to this problem?
Thank you
First of all, let me give you my custom header reader to Suggestion to extend from AdvancedDataGridHeaderRenderer to AdvancedDataGridItemRenderer instead. Secondly, it seems that you are mixing with MX: DataGrid MX: with AdvancedDataGrid . I think this is the reason of your kind of rape error. Make sure your MXML looks something like this: & lt; Mx: Enhanced Data Grid & gt; & Lt; Mx: column & gt; & Lt; Mx: AdvancedDataGrid columnDateField = "Foo" headerRenderer = "myrenderers.theHeaderRenderer" /> & Lt; / Mx: column & gt; & Lt; / Mx: AdvancedDataGrid & gt;
Comments
Post a Comment