[flexcoders] Re: DataGrid Speed
I was wondering about using labels and text as renderers and then making the editor the combobox. I'm already using ArrayCollections for providers. Do you have a feel for how much a speed improvement getting rid of combobox renderers was? Another thought is how did you indicate to the user that the label could be clicked, so they would know it would act like a combobox? Thanks for the ideas, John --- In flexcoders@yahoogroups.com, Scott - FastLane [EMAIL PROTECTED] wrote: John - I am guessing that it is the large number of complex controls (particularly combo box) you are using as renderers that is slowing you down. I had a similar situation and had to change my app such that the data rendered for combo boxes and text inputs is rendered using mx:Label or mx:Text until a user clicks on the cell... then the combo box or text input shows up (itemEditor) to allow the edit. This coupled with parsing my data into ActionScript objects and storing them in ArrayCollections and using those as grid data providers (rather than binding directly to e4x) made performance acceptable for me. hth Scott j_lentzz wrote: Hi, I have an app where it uses a datagrid to display screen data. The grid is 25 columns wide with 3 columns of comboboxes, 5 columns of checkboxes and the rest are textinputs. The number of rows varies, but can be as high as 40. What I'm seeing is that after all the server results have been processed and the data for the comboboxes (including data providers), checkboxes, etc has been passed to the data grid, the app just spins for up to 30 secs. The app code I wrote isn't doing anything specific during that time. It is just waiting for the next user event to happen. So it seems like it is the flex stuff working to maybe redraw the screen/datagrid. During this time, my processor generally pegs. Is there someway to speed up this internal processing? Or control it? I've tried reducing the number of rows displayed and that helps, but I really want to be able to display all rows at once without the 20-30sec penalty. Thanks, John
Re: [flexcoders] Re: DataGrid Speed
John - I had four columns that were displaying mx:List and 3 that were displaying mx:ComboBox, additionally I was binding directly to e4x and generating labels on the fly (labelFunction). My client likes 1600x1200 and small fonts, so I had quite a few rows on the screen. Rendering was taking between 15-30 seconds. I removed the mx:List displays and instead added String member variables to my AS objects that were formatted with \n between items then added get xyzList():String methods that the data grid then called for that column (returning the pre-formatted string). As I mentioned I also just used mx:Label as the renderer for the combo boxes and the couple of columns that were Text inputs. Additionally I removed all labelFunctions opting instead to pre-define label attributes in my AS objects (like the xyzList attribute mentioned above). After making all of these changes I was able to get redraws down to the 2-3 second range for a full scale data update... the good news is that I don't need to do a full scale update very often :) In my case, pretty much every column is editable, so I did not need to add an editable indicator although that is a great question. Seems you could easily create a EditableField custom renderer that has some type of indicator in addition to your Label or Text component. Just a thought... hth Scott j_lentzz wrote: I was wondering about using labels and text as renderers and then making the editor the combobox. I'm already using ArrayCollections for providers. Do you have a feel for how much a speed improvement getting rid of combobox renderers was? Another thought is how did you indicate to the user that the label could be clicked, so they would know it would act like a combobox? Thanks for the ideas, John --- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com, Scott - FastLane [EMAIL PROTECTED] wrote: John - I am guessing that it is the large number of complex controls (particularly combo box) you are using as renderers that is slowing you down. I had a similar situation and had to change my app such that the data rendered for combo boxes and text inputs is rendered using mx:Label or mx:Text until a user clicks on the cell... then the combo box or text input shows up (itemEditor) to allow the edit. This coupled with parsing my data into ActionScript objects and storing them in ArrayCollections and using those as grid data providers (rather than binding directly to e4x) made performance acceptable for me. hth Scott j_lentzz wrote: Hi, I have an app where it uses a datagrid to display screen data. The grid is 25 columns wide with 3 columns of comboboxes, 5 columns of checkboxes and the rest are textinputs. The number of rows varies, but can be as high as 40. What I'm seeing is that after all the server results have been processed and the data for the comboboxes (including data providers), checkboxes, etc has been passed to the data grid, the app just spins for up to 30 secs. The app code I wrote isn't doing anything specific during that time. It is just waiting for the next user event to happen. So it seems like it is the flex stuff working to maybe redraw the screen/datagrid. During this time, my processor generally pegs. Is there someway to speed up this internal processing? Or control it? I've tried reducing the number of rows displayed and that helps, but I really want to be able to display all rows at once without the 20-30sec penalty. Thanks, John
RE: [flexcoders] Re: DataGrid Speed
You will save even more time if you can use subclasses of DataGridItemRenderer instead of Text and Label. From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of j_lentzz Sent: Thursday, September 06, 2007 10:26 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] Re: DataGrid Speed I was wondering about using labels and text as renderers and then making the editor the combobox. I'm already using ArrayCollections for providers. Do you have a feel for how much a speed improvement getting rid of combobox renderers was? Another thought is how did you indicate to the user that the label could be clicked, so they would know it would act like a combobox? Thanks for the ideas, John --- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com , Scott - FastLane [EMAIL PROTECTED] wrote: John - I am guessing that it is the large number of complex controls (particularly combo box) you are using as renderers that is slowing you down. I had a similar situation and had to change my app such that the data rendered for combo boxes and text inputs is rendered using mx:Label or mx:Text until a user clicks on the cell... then the combo box or text input shows up (itemEditor) to allow the edit. This coupled with parsing my data into ActionScript objects and storing them in ArrayCollections and using those as grid data providers (rather than binding directly to e4x) made performance acceptable for me. hth Scott j_lentzz wrote: Hi, I have an app where it uses a datagrid to display screen data. The grid is 25 columns wide with 3 columns of comboboxes, 5 columns of checkboxes and the rest are textinputs. The number of rows varies, but can be as high as 40. What I'm seeing is that after all the server results have been processed and the data for the comboboxes (including data providers), checkboxes, etc has been passed to the data grid, the app just spins for up to 30 secs. The app code I wrote isn't doing anything specific during that time. It is just waiting for the next user event to happen. So it seems like it is the flex stuff working to maybe redraw the screen/datagrid. During this time, my processor generally pegs. Is there someway to speed up this internal processing? Or control it? I've tried reducing the number of rows displayed and that helps, but I really want to be able to display all rows at once without the 20-30sec penalty. Thanks, John
[flexcoders] Re: DataGrid Speed
Thanks for all the ideas. I'll give them a try and see what performance gains I get. John --- In flexcoders@yahoogroups.com, Alex Harui [EMAIL PROTECTED] wrote: You will save even more time if you can use subclasses of DataGridItemRenderer instead of Text and Label. From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of j_lentzz Sent: Thursday, September 06, 2007 10:26 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] Re: DataGrid Speed I was wondering about using labels and text as renderers and then making the editor the combobox. I'm already using ArrayCollections for providers. Do you have a feel for how much a speed improvement getting rid of combobox renderers was? Another thought is how did you indicate to the user that the label could be clicked, so they would know it would act like a combobox? Thanks for the ideas, John --- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com , Scott - FastLane smelby@ wrote: John - I am guessing that it is the large number of complex controls (particularly combo box) you are using as renderers that is slowing you down. I had a similar situation and had to change my app such that the data rendered for combo boxes and text inputs is rendered using mx:Label or mx:Text until a user clicks on the cell... then the combo box or text input shows up (itemEditor) to allow the edit. This coupled with parsing my data into ActionScript objects and storing them in ArrayCollections and using those as grid data providers (rather than binding directly to e4x) made performance acceptable for me. hth Scott j_lentzz wrote: Hi, I have an app where it uses a datagrid to display screen data. The grid is 25 columns wide with 3 columns of comboboxes, 5 columns of checkboxes and the rest are textinputs. The number of rows varies, but can be as high as 40. What I'm seeing is that after all the server results have been processed and the data for the comboboxes (including data providers), checkboxes, etc has been passed to the data grid, the app just spins for up to 30 secs. The app code I wrote isn't doing anything specific during that time. It is just waiting for the next user event to happen. So it seems like it is the flex stuff working to maybe redraw the screen/datagrid. During this time, my processor generally pegs. Is there someway to speed up this internal processing? Or control it? I've tried reducing the number of rows displayed and that helps, but I really want to be able to display all rows at once without the 20-30sec penalty. Thanks, John