Sorry, this line should be:

  <mx:DataGrid width="100%">

I'm an idiot. :)

-TH

--- In [email protected], "Tim Hoff" <[EMAIL PROTECTED]> wrote:
>
>
> Hmm, not sure what to tell you. The example below works for me; the
> third column takes up the rest of the available space. The only thing
> that I can think of, is that perhaps the width of the DataGrid is
> turning out to be smaller than the sum of the fixed column widths. In
> this case the columns would all get resized in proportion.
>
> <?xml version="1.0" encoding="utf-8"?>
> <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml";
> layout="absolute">
> <mx:DataGrid width="200">
> <mx:columns>
> <mx:DataGridColumn dataField="field1" width="200"/>
> <mx:DataGridColumn dataField="field2" width="100"/>
> <mx:DataGridColumn dataField="field3"/>
> </mx:columns>
> </mx:DataGrid>
> </mx:Application>
>
> -TH
> --- In [email protected], "ozziegt" osman.ullah@ wrote:
> >
> > That is what I have tried, and it is not working. The documentation
> > says that a datagridcolumn has a default width of 100. I haven't
been
> > able to find anything in the flex documentation to mention the
> > possibility of a variable width column.
> >
> > --- In [email protected], "Tim Hoff" TimHoff@ wrote:
> > >
> > >
> > > Are you setting explicit width values for the columns that you
want
> to
> > > remain fixed? Thie following code should keep the first two
columns
> at
> > > a fixed width and the third column should take up the rest of the
> > > variable width:
> > >
> > > <mx:DataGrid width="100%">
> > > <mx:columns>
> > > <mx:DataGridColumn dataField="field1" width="200"/>
> > > <mx:DataGridColumn dataField="field2" width="100"/>
> > > <mx:DataGridColumn dataField="field3"/>
> > > </mx:columns>
> > > </mx:DataGrid>
> > >
> > > -TH
> > >
> > > --- In [email protected], "ozziegt" <osman.ullah@> wrote:
> > > >
> > > > I have a datagrid which I want to be variable width. I need some
> of
> > > > the columns to remain fixed width while maybe one or two expand
to
> > > > fill the rest of the space. However, any solution I am trying
> isn't
> > > > working. The DataGrid is resizing all the columns. Any
> suggestions?
> > > >
> > > > Thanks
> > > >
> > >
> >
>


Reply via email to