Friday, October 29, 2010
“No Response” Display Issue in TitleBar of your AIR Project.
Solution: After R&D I found that there is property called applicationActivate in WindowedApplication which is used to solve your problem. Call below function to make your project name assigned to “title” of your application
private function applicationActivateHandler():void{
this.title = "ProjectName";
}
Print AdvancedDataGrid with property variableRowHeight related to page width.
Issue: - If you are using PrintAdvancedDataGrid and property variableRowHeight is made as "true" you can find data is not getting print properly on page (i.e. percentWidth doesnot work (percentWidth = 100)).
Solution: To make it work properly you have to follow below steps: -
Steps: -
1) Assign data to dataProvider of your PrintAdvancedDataGrid
2) Assign percentWidth = 100
3) Call validateNow()
4) Assign percentHeight = 100
5) Assign variableRowHeight=true
6) Assign wordWrap=true
These six lines will solve your problem; these lines should be in same sequence as mentioned above.
It’s interesting to work on PrintAdvancedDataGrid Component and to do R&D on it. Enjoy…….
Importing more than 10000 records in AdvancedDataGrid issue
It has been very critical to load more than 10000 records in Advanced DataGrid, there are many works around to solve this issue, after some workaround I found one of the solutions to load huge amount of data.
Difficulty faced during Debug this issue: -
1) Flex timeout: while debugging for 10000 and more records on client side.
Solution: After research I came to know that Flex gives timeout error after 2500 - 2900 records has been added in ArrayCollection which lead to Flex Timeout error.
If you are trying to load more records you have to create recursive function to handle it on client side.
setTimeout(recursiveImportHandler,200)
In recursiveImportHandler() function put “count” as variable which will keep track of record no.. Use “for loop” to add record in ArrayCollection.
Make your ArrayCollection as Bindable
Note: Your “count” should not be greater than your imported XML length.
To avoid user click you can provide Progress bar till your data gets loaded in AdvancedDataGrid.
Saturday, June 19, 2010
Issue Using (Native) Windows or Detached Window with AIR:-
Create custom component which contains Combobox and Datagrid.
Application conations two button 1) Same Window and 2) New Window. (Label of two button)
When you click on “Same Window” button your custom component should get added dynamically in your application.
And when you click on “New Window” button your custom component should get open in different window (it should get shifted from application and should appear in Window component).
Issue faced:-
Issue with DataGrid in Native window (AIR).
DataGridEvent.COLUMN_STRETCH event get affected if try to open datagrid in Native Window.
DataGridEvent get fired but takes long time or even stuck while column stretch
Tooltips all show up in the main application window rather than the popped up window by using mx:Windows and mx:WindowedApplication.
Note:
Application is a Desktop Application. Only one instance is created in Application for your custom component to preserve current state on your custom component it can be Style, data, or other subcomponent state of your custom component (as above mentioned 2 component are just sample).
Solution 1: - There is no real fix to this issue. You can recreate the component in the pop up window.
It is a heavy on performance.
Solution 2: - Use “Object polling Design Pattern” which will help you to overcome performance issue.
Welcome with good solution for this issue.