Thanks Scott,

I'd tried that, but it doesn't work.

I've also tried: 
draggableColumns="false" editable="false" allowDragSelection="false" 
lockedColumnCount="2"

but I can still change the column width (resulting in the non-visible 
columns appearing again)

Any other ideas?

--- In flexcoders@yahoogroups.com, slangeberg <[EMAIL PROTECTED]> wrote:
>
> draggableColumns="false"
> 
> -Scott
> 
> On 3/12/07, beecee1977 <[EMAIL PROTECTED]> wrote:
> >
> >   Hi,
> >
> > I've had the same problem and notice it also occurs when I resize 
the
> > column widths. Is there a way to disable being able to adjust the
> > columns? (also to prevent sorting on columns)
> >
> > Thanks
> > Bill
> >
> > --- In flexcoders@yahoogroups.com <flexcoders%
40yahoogroups.com>, "Sergey
> > Kovalyov"
> >
> > <skovalyov.flexcoders@> wrote:
> > >
> > > Hi All!
> > >
> > > I have a DataGrid and its dataProvider property is binded to
> > > ArrayCollection. When I first hide one column via
> > firstColumn.visible =
> > > false and then binding executes, that column appears again. How 
to
> > prevent
> > > this unnecessary appearance? Click "Hide Middle Name" and
> > then "Populate" in
> > > this example:
> > >
> > > <?xml version="1.0" encoding="utf-8"?>
> > >
> > > <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml";
> > >
> > > creationComplete="onCreationComplete()">
> > >
> > > <mx:Script>
> > >
> > > <![CDATA[
> > >
> > > *import* mx.collections.ArrayCollection;
> > >
> > > [*Bindable*]
> > >
> > > *protected* *var* users : ArrayCollection;
> > >
> > > *protected* *function* onCreationComplete() : *void* {
> > >
> > > users = *new* ArrayCollection();
> > >
> > > users.addItem({firstName : *"George"*, middleName : *"W"*,
> > lastName : *
> > > "Bush"*});
> > >
> > > }
> > >
> > > *protected* *function* onPopulateButtonClick() : *void* {
> > >
> > > users = *new* ArrayCollection();
> > >
> > > users.addItem({firstName : *"Victor"*, middleName : *"A"*,
> > lastName : *
> > > "Yuschenko"*});
> > >
> > > }
> > >
> > > ]]>
> > >
> > > </mx:Script>
> > >
> > > <mx:DataGrid dataProvider="{users}">
> > >
> > > <mx:columns>
> > >
> > > <mx:DataGridColumn id="firstNameDataGridColumn"
> > dataField="firstName"
> > > headerText="First Name" />
> > >
> > > <mx:DataGridColumn id="middleNameDataGridColumn"
> > dataField="middleName"
> > > headerText="Middle Name" />
> > >
> > > <mx:DataGridColumn id="lastNameDataGridColumn*"*
> > dataField="lastName"
> > > headerText="Last Name" />
> > >
> > > </mx:columns>
> > >
> > > </mx:DataGrid>
> > >
> > > <mx:Button label="Hide Middle Name*"* click="
> > > middleNameDataGridColumn.visible = *false*" />
> > >
> > > <mx:Button label="Populate" click="onPopulateButtonClick()" />
> > >
> > > </mx:Application>
> > > Sergey.
> > >
> >
> >  
> >
> 
> 
> 
> -- 
> 
> : : ) Scott
>


Reply via email to