<?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/"
	xmlns:creativeCommons="http://backend.userland.com/creativeCommonsRssModule"
	>
<channel>
	<title>Comments on: Flex &#8211; Preventing DataGrid scrolling when the dataprovider is updated.</title>
	<atom:link href="http://joelhooks.com/2008/02/07/flex-preventing-datagrid-scrolling-when-the-dataprovider-is-updated/feed/" rel="self" type="application/rss+xml" />
	<link>http://joelhooks.com/2008/02/07/flex-preventing-datagrid-scrolling-when-the-dataprovider-is-updated/</link>
	<description>[without unit tests] you're not refactoring; you're just changing shit. -Hamlet D'Arcy</description>
	<lastBuildDate>Sun, 21 Feb 2010 09:03:04 -0600</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Omer Etrog</title>
		<link>http://joelhooks.com/2008/02/07/flex-preventing-datagrid-scrolling-when-the-dataprovider-is-updated/comment-page-1/#comment-9395</link>
		<dc:creator>Omer Etrog</dc:creator>
		<pubDate>Sun, 01 Nov 2009 06:27:38 +0000</pubDate>
		<guid isPermaLink="false">http://joelhooks.com/2008/02/07/flex-preventing-datagrid-scrolling-when-the-dataprovider-is-updated/#comment-9395</guid>
		<description>Thank you, I have 3 bugs (well, for every datagrid is have different bug) on this issue</description>
		<content:encoded><![CDATA[<p>Thank you, I have 3 bugs (well, for every datagrid is have different bug) on this issue</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Paul</title>
		<link>http://joelhooks.com/2008/02/07/flex-preventing-datagrid-scrolling-when-the-dataprovider-is-updated/comment-page-1/#comment-9320</link>
		<dc:creator>Paul</dc:creator>
		<pubDate>Tue, 28 Jul 2009 00:43:07 +0000</pubDate>
		<guid isPermaLink="false">http://joelhooks.com/2008/02/07/flex-preventing-datagrid-scrolling-when-the-dataprovider-is-updated/#comment-9320</guid>
		<description>Thanks, this is exactly what I was looking for. I&#039;ll give it a try.</description>
		<content:encoded><![CDATA[<p>Thanks, this is exactly what I was looking for. I&#39;ll give it a try.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Pesse</title>
		<link>http://joelhooks.com/2008/02/07/flex-preventing-datagrid-scrolling-when-the-dataprovider-is-updated/comment-page-1/#comment-9276</link>
		<dc:creator>Pesse</dc:creator>
		<pubDate>Wed, 15 Jul 2009 08:22:56 +0000</pubDate>
		<guid isPermaLink="false">http://joelhooks.com/2008/02/07/flex-preventing-datagrid-scrolling-when-the-dataprovider-is-updated/#comment-9276</guid>
		<description>Hi, &lt;br&gt;Thanks for this snippet :)&lt;br&gt;Can you give me a hint how you use itemUpdated instead of this?&lt;br&gt;Would really appreciate it!&lt;br&gt;&lt;br&gt;Greetings,&lt;br&gt;Pesse</description>
		<content:encoded><![CDATA[<p>Hi, <br />Thanks for this snippet <img src='http://joelhooks.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> <br />Can you give me a hint how you use itemUpdated instead of this?<br />Would really appreciate it!</p>
<p>Greetings,<br />Pesse</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: joelhooks</title>
		<link>http://joelhooks.com/2008/02/07/flex-preventing-datagrid-scrolling-when-the-dataprovider-is-updated/comment-page-1/#comment-9256</link>
		<dc:creator>joelhooks</dc:creator>
		<pubDate>Wed, 08 Jul 2009 19:24:25 +0000</pubDate>
		<guid isPermaLink="false">http://joelhooks.com/2008/02/07/flex-preventing-datagrid-scrolling-when-the-dataprovider-is-updated/#comment-9256</guid>
		<description>Glad it saved you some hassle. It drove me crazy too ;)</description>
		<content:encoded><![CDATA[<p>Glad it saved you some hassle. It drove me crazy too <img src='http://joelhooks.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Matt</title>
		<link>http://joelhooks.com/2008/02/07/flex-preventing-datagrid-scrolling-when-the-dataprovider-is-updated/comment-page-1/#comment-9255</link>
		<dc:creator>Matt</dc:creator>
		<pubDate>Wed, 08 Jul 2009 18:56:04 +0000</pubDate>
		<guid isPermaLink="false">http://joelhooks.com/2008/02/07/flex-preventing-datagrid-scrolling-when-the-dataprovider-is-updated/#comment-9255</guid>
		<description>Thhhhhhhhhhhhaaaaaaaankkkk you!!!&lt;br&gt;&lt;br&gt;My god, this saved me about 3 days work!</description>
		<content:encoded><![CDATA[<p>Thhhhhhhhhhhhaaaaaaaankkkk you!!!</p>
<p>My god, this saved me about 3 days work!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: dj brikz</title>
		<link>http://joelhooks.com/2008/02/07/flex-preventing-datagrid-scrolling-when-the-dataprovider-is-updated/comment-page-1/#comment-9213</link>
		<dc:creator>dj brikz</dc:creator>
		<pubDate>Thu, 28 May 2009 09:27:13 +0000</pubDate>
		<guid isPermaLink="false">http://joelhooks.com/2008/02/07/flex-preventing-datagrid-scrolling-when-the-dataprovider-is-updated/#comment-9213</guid>
		<description>hi...thanks for the post...it works well in the application that i&#039;m doing now.  my application is fetching entries from the database and updates the datagrid every 1 second.

Wrap up solution:

1. Before updating the data provider of the datagrid, retrieve first the verticalScrollPosition and selectedItem properties of the datagrid.
2. Update the data provider of the datagrid.
3. Set again the datagrid verticalScrollPosition and selectedItem properties using the values you stored in step 1.
4. That&#039;s all and enjoy.</description>
		<content:encoded><![CDATA[<p>hi&#8230;thanks for the post&#8230;it works well in the application that i&#8217;m doing now.  my application is fetching entries from the database and updates the datagrid every 1 second.</p>
<p>Wrap up solution:</p>
<p>1. Before updating the data provider of the datagrid, retrieve first the verticalScrollPosition and selectedItem properties of the datagrid.<br />
2. Update the data provider of the datagrid.<br />
3. Set again the datagrid verticalScrollPosition and selectedItem properties using the values you stored in step 1.<br />
4. That&#8217;s all and enjoy.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: tsedeke</title>
		<link>http://joelhooks.com/2008/02/07/flex-preventing-datagrid-scrolling-when-the-dataprovider-is-updated/comment-page-1/#comment-9119</link>
		<dc:creator>tsedeke</dc:creator>
		<pubDate>Sun, 05 Apr 2009 10:43:15 +0000</pubDate>
		<guid isPermaLink="false">http://joelhooks.com/2008/02/07/flex-preventing-datagrid-scrolling-when-the-dataprovider-is-updated/#comment-9119</guid>
		<description>Joel,
in some cases you are right, but if you have an application getting data from database where also many people work on, it is important to read all records after changing, cause not only your record may change.
In this situation you have no other chance, you have to remember your key of your record and after refresh find and select it again.
Cause today we are not able to make a specific record update in a Arraycollection from a database. 
Ok you can do it, but it is not save and cause an overhead.

Thorsten</description>
		<content:encoded><![CDATA[<p>Joel,<br />
in some cases you are right, but if you have an application getting data from database where also many people work on, it is important to read all records after changing, cause not only your record may change.<br />
In this situation you have no other chance, you have to remember your key of your record and after refresh find and select it again.<br />
Cause today we are not able to make a specific record update in a Arraycollection from a database.<br />
Ok you can do it, but it is not save and cause an overhead.</p>
<p>Thorsten</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Chris</title>
		<link>http://joelhooks.com/2008/02/07/flex-preventing-datagrid-scrolling-when-the-dataprovider-is-updated/comment-page-1/#comment-3867</link>
		<dc:creator>Chris</dc:creator>
		<pubDate>Sun, 11 Jan 2009 21:03:09 +0000</pubDate>
		<guid isPermaLink="false">http://joelhooks.com/2008/02/07/flex-preventing-datagrid-scrolling-when-the-dataprovider-is-updated/#comment-3867</guid>
		<description>Joel,

could you post the code where this is implemented?  This is something I have been looking for. Thanks for the help!</description>
		<content:encoded><![CDATA[<p>Joel,</p>
<p>could you post the code where this is implemented?  This is something I have been looking for. Thanks for the help!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Joel</title>
		<link>http://joelhooks.com/2008/02/07/flex-preventing-datagrid-scrolling-when-the-dataprovider-is-updated/comment-page-1/#comment-824</link>
		<dc:creator>Joel</dc:creator>
		<pubDate>Fri, 30 May 2008 14:28:40 +0000</pubDate>
		<guid isPermaLink="false">http://joelhooks.com/2008/02/07/flex-preventing-datagrid-scrolling-when-the-dataprovider-is-updated/#comment-824</guid>
		<description>I&#039;ve never seen it go to the bottom like that!

If you want it to go to the top, do this:

myDataGrid.selectedIndex = 0
myDataGrid.scrollToIndex(0)

That will reposition and select the first entry. To make it &#039;smart&#039; you want to record the position of the item you are deleting, and have it select/scroll there.</description>
		<content:encoded><![CDATA[<p>I&#8217;ve never seen it go to the bottom like that!</p>
<p>If you want it to go to the top, do this:</p>
<p>myDataGrid.selectedIndex = 0<br />
myDataGrid.scrollToIndex(0)</p>
<p>That will reposition and select the first entry. To make it &#8217;smart&#8217; you want to record the position of the item you are deleting, and have it select/scroll there.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Hari</title>
		<link>http://joelhooks.com/2008/02/07/flex-preventing-datagrid-scrolling-when-the-dataprovider-is-updated/comment-page-1/#comment-818</link>
		<dc:creator>Hari</dc:creator>
		<pubDate>Fri, 30 May 2008 06:51:18 +0000</pubDate>
		<guid isPermaLink="false">http://joelhooks.com/2008/02/07/flex-preventing-datagrid-scrolling-when-the-dataprovider-is-updated/#comment-818</guid>
		<description>Hi, my datagrid is bound to an ArrayCollection which is the dataprovider. When I remove items from Arraycollection, the focus on the datagrid moves to the bottom of the grid which deiplays a blank row. I want the focus to be remained always at the top. Please let me know any way to solve this.</description>
		<content:encoded><![CDATA[<p>Hi, my datagrid is bound to an ArrayCollection which is the dataprovider. When I remove items from Arraycollection, the focus on the datagrid moves to the bottom of the grid which deiplays a blank row. I want the focus to be remained always at the top. Please let me know any way to solve this.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
