<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	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/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Flex Examples &#187; DataGrid.variableRowHeight</title>
	<atom:link href="http://blog.flexexamples.com/tag/datagrid-variablerowheight/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.flexexamples.com</link>
	<description>Just a bunch of Adobe Flex Examples</description>
	<lastBuildDate>Wed, 26 Jan 2011 18:09:51 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Creating multi-line data grid rows with variable row heights</title>
		<link>http://blog.flexexamples.com/2007/07/23/creating-multi-line-data-grid-rows-with-variable-row-heights/</link>
		<comments>http://blog.flexexamples.com/2007/07/23/creating-multi-line-data-grid-rows-with-variable-row-heights/#comments</comments>
		<pubDate>Tue, 24 Jul 2007 01:04:51 +0000</pubDate>
		<dc:creator>Peter deHaan</dc:creator>
				<category><![CDATA[DataGrid]]></category>
		<category><![CDATA[DataGridColumn]]></category>
		<category><![CDATA[DataGrid.variableRowHeight]]></category>
		<category><![CDATA[DataGridColumn.wordWrap]]></category>

		<guid isPermaLink="false">http://blog.flexexamples.com/2007/07/23/creating-multi-line-data-grid-rows-with-variable-row-heights/</guid>
		<description><![CDATA[<p>One of my favorite Flex components is the the trusty DataGrid. It seems whenever I build some sort of application or sample, I need a DataGrid to show all sorts of debug data or what have you. Here is a simple little example of a DataGrid with multi-line content and a variable row height.</p> <p>Full [...]]]></description>
			<content:encoded><![CDATA[<p>One of my favorite Flex components is the the trusty DataGrid. It seems whenever I build some sort of application or sample, I need a DataGrid to show all sorts of debug data or what have you. Here is a simple little example of a DataGrid with multi-line content and a variable row height.</p>
<p>Full code after the jump.</p>
<p><span id="more-16"></span></p>
<p>The following example demonstrates how to set up a DataGrid control to word wrap certain data grid columns, and allow each row to have a variable row height, depending on the amount of text in each row:</p>
<p class="download"><a href="http://blog.flexexamples.com/wp-content/uploads/DataGrid_variableRowHeight_test/main.mxml">View MXML</a></p>
<pre class="code">
&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;!-- http://blog.flexexamples.com/2007/07/23/creating-multi-line-data-grid-rows-with-variable-row-heights/ --&gt;
&lt;mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" backgroundColor="white" layout="vertical"&gt;

    &lt;mx:Array id="arr"&gt;
        &lt;mx:Object articleName="Finding out a characters Unicode character code" data="15" /&gt;
        &lt;mx:Object articleName="Setting an icon in an Alert control" data="14" /&gt;
        &lt;mx:Object articleName="Setting an icon in a Button control" data="13" /&gt;
        &lt;mx:Object articleName="Installing the latest nightly Flex 3 SDK build into Flex Builder 3" data="10" /&gt;
        &lt;mx:Object articleName="Detecting which button a user pressed to dismiss an Alert dialog" data="9" /&gt;
        &lt;mx:Object articleName="Using the Alert control" data="8" /&gt;
        &lt;mx:Object articleName="Formatting data tips in a Slider" data="7" /&gt;
        &lt;mx:Object articleName="Downloading the latest Adobe Labs version of Flex 3 SDK/Flex Builder 3 (codename: Moxie)" data="6" /&gt;
    &lt;/mx:Array&gt;
    &lt;mx:ArrayCollection id="arrColl" source="{arr}" /&gt;

    &lt;mx:DataGrid id="dataGrid" dataProvider="{arrColl}" variableRowHeight="true" width="100%" height="100%"&gt;
        &lt;mx:columns&gt;
            &lt;mx:DataGridColumn id="articleName" dataField="articleName" headerText="Name of the article in question" wordWrap="true" /&gt;
            &lt;mx:DataGridColumn id="data" dataField="data" headerText="ID of the article" /&gt;
        &lt;/mx:columns&gt;
    &lt;/mx:DataGrid&gt;

&lt;/mx:Application&gt;
</pre>
<p class="information"><a href="http://blog.flexexamples.com/wp-content/uploads/DataGrid_variableRowHeight_test/bin/srcview/index.html">View source</a> is enabled in the following example.</p>
<p><iframe src="http://blog.flexexamples.com/wp-content/uploads/DataGrid_variableRowHeight_test/bin/main.html" width="100%" height="200"></iframe></p>
<div class="evernoteSiteMemory"><a href="javascript:" onclick="Evernote.doClip({title: 'Creating multi-line data grid rows with variable row heights on FlexExamples.com',url: 'http://blog.flexexamples.com/2007/07/23/creating-multi-line-data-grid-rows-with-variable-row-heights/',contentID: 'post-16',code: 'Pete9667',suggestNotebook: 'FlexExamples',suggestTags: 'DataGrid.variableRowHeight,DataGridColumn.wordWrap',providerName: 'FlexExamples.com',styling: 'text' });return false" class="evernoteSiteMemoryLink"><img src="http://static.evernote.com/article-clipper-remember.png" class="evernoteSiteMemoryButton" />
				</a>				<div class="evernoteSiteMemoryClear">&nbsp;</div>
</div>]]></content:encoded>
			<wfw:commentRss>http://blog.flexexamples.com/2007/07/23/creating-multi-line-data-grid-rows-with-variable-row-heights/feed/</wfw:commentRss>
		<slash:comments>20</slash:comments>
		</item>
	</channel>
</rss>

