<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Set DataGridColumn&#8217;s width in percentage with ease</title>
	<atom:link href="http://www.daveoncode.com/2009/03/18/set-datagridcolumns-width-in-percentage-with-ease/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.daveoncode.com/2009/03/18/set-datagridcolumns-width-in-percentage-with-ease/</link>
	<description>coder and technology lover</description>
	<lastBuildDate>Fri, 03 Sep 2010 13:41:46 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
	<item>
		<title>By: DD</title>
		<link>http://www.daveoncode.com/2009/03/18/set-datagridcolumns-width-in-percentage-with-ease/comment-page-1/#comment-6123</link>
		<dc:creator>DD</dc:creator>
		<pubDate>Fri, 28 May 2010 13:07:26 +0000</pubDate>
		<guid isPermaLink="false">http://www.daveoncode.com/?p=350#comment-6123</guid>
		<description>Thanks for this post
Now it&#039;s WAAAY easier for me to deal with multiple DataGridColumn widths.</description>
		<content:encoded><![CDATA[<p>Thanks for this post<br />
Now it&#8217;s WAAAY easier for me to deal with multiple DataGridColumn widths.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Abhishek</title>
		<link>http://www.daveoncode.com/2009/03/18/set-datagridcolumns-width-in-percentage-with-ease/comment-page-1/#comment-4973</link>
		<dc:creator>Abhishek</dc:creator>
		<pubDate>Mon, 08 Feb 2010 09:13:17 +0000</pubDate>
		<guid isPermaLink="false">http://www.daveoncode.com/?p=350#comment-4973</guid>
		<description>This code has helped a lot. It perfevtly works.
Thanks for posting it.</description>
		<content:encoded><![CDATA[<p>This code has helped a lot. It perfevtly works.<br />
Thanks for posting it.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Banksy</title>
		<link>http://www.daveoncode.com/2009/03/18/set-datagridcolumns-width-in-percentage-with-ease/comment-page-1/#comment-3526</link>
		<dc:creator>Banksy</dc:creator>
		<pubDate>Tue, 03 Nov 2009 21:34:22 +0000</pubDate>
		<guid isPermaLink="false">http://www.daveoncode.com/?p=350#comment-3526</guid>
		<description>Excellent, well done</description>
		<content:encoded><![CDATA[<p>Excellent, well done</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: JabbyPanda</title>
		<link>http://www.daveoncode.com/2009/03/18/set-datagridcolumns-width-in-percentage-with-ease/comment-page-1/#comment-3282</link>
		<dc:creator>JabbyPanda</dc:creator>
		<pubDate>Wed, 14 Oct 2009 09:02:33 +0000</pubDate>
		<guid isPermaLink="false">http://www.daveoncode.com/?p=350#comment-3282</guid>
		<description>Hi Davide,

You&#039;ve described an smart and simple to code workaround for &quot;how-to&quot; specify percentage width values for the width of Adobe Flex Datagrid&#039;s columns.

Unfortunately, this workaround is not applicable if the developer will specify explicit &quot;minWidth&quot; value for any column.

Nate&#039;s extension for DataGrid called ScalableDataGrid looks and works in more solid way to provide the support for percentage width values for DataGrid&#039;s columns:

http://natescodevault.com/?p=67</description>
		<content:encoded><![CDATA[<p>Hi Davide,</p>
<p>You&#8217;ve described an smart and simple to code workaround for &#8220;how-to&#8221; specify percentage width values for the width of Adobe Flex Datagrid&#8217;s columns.</p>
<p>Unfortunately, this workaround is not applicable if the developer will specify explicit &#8220;minWidth&#8221; value for any column.</p>
<p>Nate&#8217;s extension for DataGrid called ScalableDataGrid looks and works in more solid way to provide the support for percentage width values for DataGrid&#8217;s columns:</p>
<p><a href="http://natescodevault.com/?p=67" rel="nofollow">http://natescodevault.com/?p=67</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Dipanjan</title>
		<link>http://www.daveoncode.com/2009/03/18/set-datagridcolumns-width-in-percentage-with-ease/comment-page-1/#comment-2849</link>
		<dc:creator>Dipanjan</dc:creator>
		<pubDate>Wed, 26 Aug 2009 15:15:56 +0000</pubDate>
		<guid isPermaLink="false">http://www.daveoncode.com/?p=350#comment-2849</guid>
		<description>This is really awesome !!!
Wonder why the documentation does not through any light on this...</description>
		<content:encoded><![CDATA[<p>This is really awesome !!!<br />
Wonder why the documentation does not through any light on this&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Davide Zanotti</title>
		<link>http://www.daveoncode.com/2009/03/18/set-datagridcolumns-width-in-percentage-with-ease/comment-page-1/#comment-2226</link>
		<dc:creator>Davide Zanotti</dc:creator>
		<pubDate>Wed, 17 Jun 2009 11:59:51 +0000</pubDate>
		<guid isPermaLink="false">http://www.daveoncode.com/?p=350#comment-2226</guid>
		<description>@GarykPatton: I usually write new posts on my blog once a week (more or less)</description>
		<content:encoded><![CDATA[<p>@GarykPatton: I usually write new posts on my blog once a week (more or less)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: GarykPatton</title>
		<link>http://www.daveoncode.com/2009/03/18/set-datagridcolumns-width-in-percentage-with-ease/comment-page-1/#comment-2216</link>
		<dc:creator>GarykPatton</dc:creator>
		<pubDate>Tue, 16 Jun 2009 03:09:30 +0000</pubDate>
		<guid isPermaLink="false">http://www.daveoncode.com/?p=350#comment-2216</guid>
		<description>Hello. I think the article is really interesting. I am even interested in reading more. How soon will you update your blog?</description>
		<content:encoded><![CDATA[<p>Hello. I think the article is really interesting. I am even interested in reading more. How soon will you update your blog?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: KattyBlackyard</title>
		<link>http://www.daveoncode.com/2009/03/18/set-datagridcolumns-width-in-percentage-with-ease/comment-page-1/#comment-2208</link>
		<dc:creator>KattyBlackyard</dc:creator>
		<pubDate>Mon, 15 Jun 2009 01:32:00 +0000</pubDate>
		<guid isPermaLink="false">http://www.daveoncode.com/?p=350#comment-2208</guid>
		<description>Hi, gr8 post thanks for posting. Information is useful!</description>
		<content:encoded><![CDATA[<p>Hi, gr8 post thanks for posting. Information is useful!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Davide Zanotti</title>
		<link>http://www.daveoncode.com/2009/03/18/set-datagridcolumns-width-in-percentage-with-ease/comment-page-1/#comment-904</link>
		<dc:creator>Davide Zanotti</dc:creator>
		<pubDate>Thu, 23 Apr 2009 07:50:13 +0000</pubDate>
		<guid isPermaLink="false">http://www.daveoncode.com/?p=350#comment-904</guid>
		<description>You are perfectly right Nate, I don&#039;t tried a combination like your example in my test :P
Thanks for the catch ;)

ps. Anyway you can play with minWidth property of percentage columns, something like:

&lt;code&gt;
&lt;mx:DataGridColumn dataField=&quot;firstname&quot; width=&quot;0.2&quot; minWidth=&quot;120&quot; /&gt;
&lt;/code&gt;

doesn&#039;t solve the problem, but can help :)</description>
		<content:encoded><![CDATA[<p>You are perfectly right Nate, I don&#8217;t tried a combination like your example in my test :P<br />
Thanks for the catch ;)</p>
<p>ps. Anyway you can play with minWidth property of percentage columns, something like:</p>
<div class="codecolorer-container text mac-classic" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">&lt;mx:DataGridColumn dataField=&quot;firstname&quot; width=&quot;0.2&quot; minWidth=&quot;120&quot; /&gt;</div></td></tr></tbody></table></div>
<p>doesn&#8217;t solve the problem, but can help :)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Nate Ross</title>
		<link>http://www.daveoncode.com/2009/03/18/set-datagridcolumns-width-in-percentage-with-ease/comment-page-1/#comment-896</link>
		<dc:creator>Nate Ross</dc:creator>
		<pubDate>Thu, 23 Apr 2009 00:25:42 +0000</pubDate>
		<guid isPermaLink="false">http://www.daveoncode.com/?p=350#comment-896</guid>
		<description>Your solution only works for percentages, but not a combination of the two. What if I want the first column to be 70%, the second to be 30%, and the last to be 50 pixels like this...

&lt;code&gt;
&lt;mx:DataGrid dataProvider=&quot;{dummyData}&quot; width=&quot;100%&quot; height=&quot;300&quot;&gt;
&lt;mx:columns&gt;
&lt;mx:DataGridColumn dataField=&quot;label&quot; width=&quot;0.7&quot;/&gt;
&lt;mx:DataGridColumn dataField=&quot;data&quot; width=&quot;0.3&quot;/&gt;
&lt;mx:DataGridColumn dataField=&quot;extra&quot; width=&quot;50&quot;/&gt;
&lt;/mx:columns&gt;
&lt;/mx:DataGrid&gt; 
&lt;/code&gt;

The result is that the last column is gigantic whereas the other two are tiny. The reason is because the DataGrid takes the total of all the widths and then uses the total width of the DataGrid to allocate a percentage to each. For purely percentage-based columns, this works, but not for a combination.</description>
		<content:encoded><![CDATA[<p>Your solution only works for percentages, but not a combination of the two. What if I want the first column to be 70%, the second to be 30%, and the last to be 50 pixels like this&#8230;</p>
<div class="codecolorer-container text mac-classic" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br />2<br />3<br />4<br />5<br />6<br />7<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">&lt;mx:DataGrid dataProvider=&quot;{dummyData}&quot; width=&quot;100%&quot; height=&quot;300&quot;&gt;<br />
&lt;mx:columns&gt;<br />
&lt;mx:DataGridColumn dataField=&quot;label&quot; width=&quot;0.7&quot;/&gt;<br />
&lt;mx:DataGridColumn dataField=&quot;data&quot; width=&quot;0.3&quot;/&gt;<br />
&lt;mx:DataGridColumn dataField=&quot;extra&quot; width=&quot;50&quot;/&gt;<br />
&lt;/mx:columns&gt;<br />
&lt;/mx:DataGrid&gt;</div></td></tr></tbody></table></div>
<p>The result is that the last column is gigantic whereas the other two are tiny. The reason is because the DataGrid takes the total of all the widths and then uses the total width of the DataGrid to allocate a percentage to each. For purely percentage-based columns, this works, but not for a combination.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
