Flex :: How To Add List Box
May 31, 2010I want to add simple list/combo box with action script 3 . but i have not found anything in internet.
View 2 RepliesI want to add simple list/combo box with action script 3 . but i have not found anything in internet.
View 2 RepliesI'm using flex 4.1 to write an application. i read in the documents that has the rowCount property to set how many items to display. the does not have that property. how can I limit the list to display 3 items ?
View 3 RepliesFlex 3 List control had a itemRollOver event. Flex 4 List doesn't have it. Is there an equivalent or a workaround for this issue?
View 2 RepliesHere is a snip from within my code:
[Code]...
The 'recommendations' dataProvider is an ArrayCollection of String, which are generally sentences about as long as this one. By setting the variableRowHeight and wordWrap properties as shown, if a sentence is too long to fit on a single line, everything works fine- the row expands and the messages show on two lines, or occasionally three.
The space allocated for this panel within the entire canvas means if the total text size of 'recommendations' exceeds six lines, I need for the entire list scroll. This is also working just fine. The trouble is when using the mouse wheel to do the scrolling- Flex scrolls both the entire list and the single item where the mouse is hovering. Often this results in only the second half of a sentence being visible. Non-programmer friends I have asked to look at this noticed this, and tell me it as a problem. If a user does not notice the dual scrolling, and sees only a fragment of a sentence, it will be perceived as an error in the application.
[Code]....
When a user selects a category from the first drop down box then i want the 2nd drop down to be updated based on the selection of the first drop down. I have created multiple ArrayCollections whose names are set to the "data" values of the first drop down, for instance:
[Bindable]
public var countries:ArrayCollection = new ArrayCollection([
{label:"USA",data:"USA"},
[code].....
I am currently working on a project in Flex and I am having a hard time having a list's contents ALL be selected by default. Wondering how to do this.
<mx:List id="list" dataProvider="{dp}" allowMultipleSelection="true"/>
I'm just trying to have the list all selected.
I'm trying to animate a list as I delete the top row. All the examples I can find use itemsChangeEffect to bind to the effect, but this property exists only in MX lists, not spark lists.
Any idea how I can get the same effect done in Spark Lists?
I'm trying to remove the top most item in the list with a slight fade out effect before the rest of the items move up to replace the gap.
while i using drag & drop from listbox1 to listbox2 ,how can i get all the items of listbox2 in flex
View 1 RepliesThe traditional way to assign an icon would be to use the icon field of the item renderer,which reads the value of "icon" property in your data, for example:
listData.addItem({label: "Logout", icon: "com.classpth.DefualtThemeLogoutIconClass"});
But i want the DefualtThemeLogoutIconClass to changed to another class: ightThemeLogoutIconClass when the theme is changed.The only way to do this would be to use a style declaration containing a classReference to the icon, and change its the value in each of the CSS files of the various themes.The question is, is there any way to assign this style to an icon in a List, something as easy as intuitive as list[0].getIcon().setStyle("styleName");
I have a drop down list for selecting the titles for a person, I want to employ smooth drop down when i select the drop down menu.
View 1 RepliesI want to create a list of progress bars and update the list accordingly.I have group data in an Array as
<mx:Array id="arr">
<mx:Object label="Group One" min="0" max="200" currentValue="60" />
<mx:Object label="Group Two" min="0" max="300" currentValue="50" />[code]....
The values in the array object indicate name of group,minimum,maximum and current value for the group (to be used in progressbar).I used the list with "mx.controls.ProgressBar" as itemRenderer as
<mx:List width="100%" dataProvider="{arr}"
itemRenderer="mx.controls.ProgressBar"/>
Now what I need is whenever currentValue field of Array "arr" changes i want to update the progressbar "progress" value to currentValue (where min and maximum value of progressbar are stored in Array "arr").
Here is the code I am using in the label function. Some of the values are numbers and some are strings. It works:
private function getLabel (area:AreasVO):String
{
return "Area Name: " + area.areaName + " " + area.areaWidth + " X " + area.areaLength + " X " + area.areaHeight;[code].........
I just get error upon error...Numbers as Strings or a bunch of others...How do I do this?
How can locate text in the mx:List like this?
[Code]...
I am having a strange QNX problem here in Flex (Adobe AIR), I have created an init(); function and in it I have added the test_list() function yet the QNX List is just not showing up on the UI. [code]...
View 1 RepliesIs it possible to add bullets to a Label in Flex 4.5 mobile development?something like this:
.Item
.Item
.Item
i have a simple xml like so:
<root Name="Bob" isImployed="true">
<customer Name="Bob" id="12345">was addressed in the shopping mall</customer>
<Job-title>Insurance</Job-title>
<experience>15</experience>
<Question1 question="how much do you make?">35000</Question1>
<Question2 question="do you get a yearly bonus?">5000</Question2>
<Question3 question="would you be interested in our weekly plan?">yes</Question3>
</root>
[Code]...
I would like to go over all the questions (there are more than question1,question2 and question3). some of those contain numbers (salary, bouns) and some don't. I am looking for a way to go over the whole list, querying if the answer is a number or not, and if so - get the number. (and do some calculation with it).
I've got a spark list that gets dynamically filled.So far the new items appear at the bottom of the list. What I'd like to do is to add them at the top.The items in the list have a unique ID so some kind of sorting mechanism would probably do the trick as the new items have a greater ID than the old ones.What I'd like to avoid is some complex method behind this as I'm working on a mobile platform and the list can get quite big so I need this to be as efficient as possible.The list's data provider is an ArrayList that gets updated using binding.
View 1 RepliesI have a problem with BlazeDS to Flex mobile deserialization, so that I try to send back list of maps List<Map<String, Object>> with different Objects in every Map, but when I receive this list in flex code:
hastalarim = event.result as ArrayCollection; But when I debug this in flex code I see that there're 7 instances of the same Object (the first object that was inserted on server-side) in that list.
[Code]...
I am a Java developer who tries Flex.I have a list component in Flex filled by objects got from Java (by binding dataprovider).I have put drag-drop support on list.Everything is good.But I wanted to have a reset function to reinitialize list, namely get back drag-dropped elements to the list.I tried several thing on event handler of reset button but could not reinitialise the list data. For example:
public function resetList():void {
trace("reset")
listsrc.dataProvider = srv.getTerritories.lastResult
}
"reset" is debugged but there is no change on list.
what I need to do is get a list of files in a folder in a Flex application from the web (i.e. all the files in a location like [URL]
View 2 RepliesHow can I validate if atleast one item has been selected from a list, such that the selectedIndices is set to NULL at the init() of application?
View 1 RepliesIs it possible to get list of installed AIR applications, optionally only by one vendor?
Or, is it possible to check, whether is one application (checked by name/some id/vendor) installed (this method would be preferred)
Is there something like selectedIndex for SkinnableDataContainer? It doesn't seem to be one of the available properties.
View 2 RepliesIt seems like it should be a simple concept. I need a vertical list. This list has an image with a checkbox and pathname of that image underneath it. The user should be able to check the checkboxes of the images they want to appear in their "shopping cart". The images, checkbox label, and list are populated by an XmlList. How can I do this in Flex 3.5 and Actionscript and have a button that when clicked, display a list of the checked items??
View 1 RepliesHow to access List itemRenderer and its properties (Spark - Flex 4)?I want to iterate through list and do something like (note it's pseudo code):
for (var i=0;i<NUMBER_OF_ITEMS_IN_LIST; i++){
myList.getItemRenderer[i].property
}
[code].....
In flex UI, my <mx:list> can not be shown completely because of other component shelterring (for example: the refresh button shelter part of it ). How can I make the <mx:list> in front of all other UI component.
This is my code:
<s:HGroup verticalAlign="middle">
<s:Label text="Choose Log File"/>
<mx:ComboBox id ="logFileChooseCombo" dataProvider="{fileNameList}" width="150" color="0x000000"
[Code]....
I have a Flex list and a custom ItemRenderer. I'd like to be able to have some items in the list use a different ItemRenderer (say, depending on the class of the item). Is this possible?
E.g.: <s:List dataProvider="{_systems}" itemRenderer="myItemRenderer"/>
Most items in _systems use myItemRenderer. But if element 3 of _systems is "specialSystem" the renderer would be "specialItemRenderer".
By default, whenever you rollOver/mouseOver (not sure of the difference) an item in a Datagrid or a List, that item is highlighted with the component's rollOverColor.I'm just wondering if there's any way to do that programmatically. I haven't been able to find much help on the issue. For example,suppose I have two DataGrids.When I rollOver an item in the first DataGrid, I want to highlight the corresponding index in the second one as well.Basically, as if two separate cursors were rollOver'ing two separate DataGrids.
View 2 RepliesThe code
for ( var i:int = 0; i < markers.length; i++ )
{
markers[i].addEventListener( MapMouseEvent.CLICK, function( e:Event ):void
[code].....
I want to know if I can use a tree and when and item in the tree is clicked the viewstack changes to that certain item?
View 1 Replies