On Wed, Jan 14, 2009 at 3:40 PM, Wesley Acheson <wesley.ache...@gmail.com> wrote:
>> Okay sorry If I wasn't clear enough about it basically the data grid >> stretches, but not enough to accomidate all columns. Nor even enough to fill >> the container. Setting a width of 0 makes the datagrid remember its >> constraint layout. Some other intresting factors in my test case if I leave >> on column not dynamically created specified in the mxml, and replace it with >> the dynamic columns then it works correctly. >> [...] I've told you what your basic problem is: The DatarGrid's minWidth is greater than the Panel's width. You could come up with any number of scenarios in which this happens -- it doesn't matter. If you add a 100 columns to the DataGrid, it will compute its minWidth based on how much space it thinks it needs. The way to override that is to set the minWidth explicitly. If you try this with the sample you posted, you'll see that you get the desired behavior. <DataGrid minWidth="1" ... /> Manish