7 Replies Latest reply on Feb 27, 2009 3:25 PM by Handycam

    Hide a DataGrid Column in a State?

    Handycam Level 1
      In one state, I want to show all columns. In a second state, I want to hide a few columns and made the grid smaller.

      I have:
      <mx:State name="detail">
      <mx:AddChild relativeTo="{hbox1}" position="lastChild">
      <ns:DetailPanel id="detailPanel" />
      </mx:AddChild>
      <mx:SetProperty target="{listPanel}" name="width" value="450"/>
      </mx:State>
      </mx:states>

      I know how to hide a column in Actionscript, but I thought it would be more convenient to make it part of the state.