Flash :: Flex - Search In ArrayCollection By Part Of The Word
Jun 8, 2010For example i have an ArrayCollection, and i want to find persons with telephone begines with "944" how can i do this?
[Code]....
For example i have an ArrayCollection, and i want to find persons with telephone begines with "944" how can i do this?
[Code]....
so I have a string "bla dla dla vre bla 54312" I want to turn it into "bla dla dla " by saying something like
function(string, "vre");
how to do such thing?
[URL]I client want some thing like this. User will search a word and application searches that word in a opened page and highlight it. This is a Flash application and uses php at back-end to generate XML.
View 2 RepliesI'm trying to make it so that when a user inputs the correct word an event happens. It almost works except that the event doesn't fire until the NEXT keystroke. Is there a way to test for the word AFTER the keystroke has become part of WriteInOneText.text, without adding a separate button or anything? Here's the code:
[Code]...
AS2, + CS4 Flash I am trying to develop a 'Nearest Store Locator' in flash for part of my website. Basically instead of having all of my stockists and stores listed on the website, I would like to have an input box, where a user can put in their Postcode, and the flash swf will search the stores we stock by the postcode(s) and bring up the closest 3 - 5 stores. Is this possible to do,
View 1 RepliesI am looking to develop an application to read in a list of 10000+ wordlist and create a function which efficiently and quickly checks if the word exists on the list.function shd be optimized to be called several times..
View 3 RepliesIs possible to search for a word in *all* the open files using Flash IDE ?
View 1 RepliesI found this handy function...
String.prototype.replace = function(find,replace){
return this.split(find).join(replace).toString();
}
// Example:
foo = "Let's replace all the e's in this sentence with an o.";
trace(foo.replace("e","o"))
How would I replace the first "e" with "a", the second "e" with "b", etc...
I'm trying to figure out how to get this started. I'd like to type a word in a textfield and have it search for a match through a list of words in xml. There would be 26 xml files containing a list of words starting with a letter of the alphabet.
View 2 RepliesI'm new to Flex and am using TileList bound to an ArrayCollection. The array collection is empty at load time, and then updates with the results from am HTTPService call. The problem is that the item renderers aren't being rendered as expected, I'm guessing because there was no data when they were first rendered at load time. Here's simplified example:
<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" >
<mx:Script>
[code].....
is there any way to use ArrayCollection (from mx.collections.*) in Flash CS3/4/5? How?
View 2 RepliesMy label text is not showing up after binding the arraycollection to the label text. Could I see an example of how to properly bind an arraycollection to a labels text?
View 2 RepliesI am using Adobe Flash Builder 4 Premium. I have a mx:DataGrid and a s:TextInput, and I am trying to set up a search box that filters the DataGrid on each key press.his page shows a nearly perfect example of what I'm trying to do, except that I'm setting this up in a s:TitleWindow, which is brought up as a popup using the PopUpManager. The list I'm trying to filter can be very large. It is a list of usernames, fetched from a MySQL database via PHP. Since it can be so large, I want the list to be populated once in the main application and then referenced in the popup window so that it doesn't have to fetch all the usernames each time the user opens the popup.I have all of this working fine for the first time you bring up the popup, but if you close it and bring it up again, I get this runtime error:I also get this error if I attempt to set the filterFunction back to null just before closing the popup.See sample code below:
Main Application:
<?xml version="1.0" encoding="utf-8"?>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
[code]......
How can I make a word file (.doc) from flash builder (air application)? Is there any library to do that?
View 1 RepliesI am evaluating flex for a mobile and a web application and one of things I want to be able to do is show a google docs or a microsoft docs file (doc,ppt) within a flex application. Google docs files are published as web pages so I guess you need a html component with javascript enabled. Does such a component exist in flex 4+? Similarly how would I go about showing a word or a powerpoint file inside a flex app? How does a site like slideshare or scribd do it?
View 1 RepliesI would like to change the visibility of specific part of the skin at run time, but i dont know how to reach it.
View 2 RepliesI need to make part of a flex skin non-focusable/non-clickable, i.e. so that when the mouse clicks that part of the button, it doesn't actually get clicked. Basically, I want that part to be a shadow or highlight or background or whatever you'd like to call it.It's done somehow with drop shadows but I want to have finer control than using filters.Example code:
<s:SparkSkin xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark" >
<fx:Metadata>
[code].....
I am trying to add a search field to an Adobe Flex project and when you type in the newly created search field, I get the following Error:[code]
View 2 RepliesI have been building a simple word game. It is smple but works fine. I am now trying to enhance some of the features.I would like to see if I can display one letter of each word so the Player has a hint. Think of this as a beginners level.The words are random from a text list. Either I can make the letters invisible and the game starts without a hint or I am able to select a letter using charAt() or creating a new variable substring()from the word which is the displayed repeatedly on the stage(not what I want) I have not been able to find a way to display one letter and display it in the correct order within the word and keep the remaining letters invisible.
import flash.net.URLLoader;
import flash.events.Event;
import flash.display.MovieClip;
import flash.text.TextField;
[code]...
I have a advanced datagrid and populating some data by using arraycollection. And i am filtering the arraycollection, the arraycollection index got changed.
Arraycollection:- [0] - name: abc
[1] - name: hello
[2] - name: hello1
[3] - name:hai
after filtering the arraycollection as 'hell' , the array collection is displaying like the below:
Arraycollection:-
[0] - name: hello1
[1] - name: hello
Can i know the reason why the index got changed after filter it?
* no server side code for filtering. it is only flex side filtering.
I am doing drag-the-word quiz. When you match the word with correct part, the message pop out, saying Bingo! If the word is matched with wrong part, the "Sorry. Try Again" message pops out, says "Sorry. Try Again". I managed to make the "Sorry. Try Again" message disappear. However it dun work anymore after that. Sometimes it is quite funny. When I play it, the "Sorry. Try Again" message dun pop out at all.
Another problem - I am not sure how to make the word fit into the white box. I only know how to make the word drop on the white box. Can you tell me how to do it? I will be adding voiceovers to the quiz when the word is matched with the part. For e.g it will say "bingo" or "Sorry. Try Again". How to attach the voiceovers to it?
create the word which changing many time and in the end become a clear word like what's happend exactly in horizintal menu in [URL] That's what i wanted the changing in words like that menu?
View 3 RepliesI'am looking for a flv/video player which allow to seek for not loaded part of the video,just like on youtube.
View 1 Repliesi have a problem using the itemRenderer functionality. When using an ArrayCollection the visible Data in the DataGrid using the itemRenderer will be rendered just fine. But if i start scrolling the entries are repeating in the cells using the renderer. The cells are not filled with date according to the id. What mistake i'm doing here.
I read a lot of the explainations like:
[URL]
here is the code for the set data function (itemRenderer is extending HBox):
override public function set data(value:Object):void {
_data = value;
if(data!=null)
[code]....
Ok so If I load a list of like 2000 words from a text file into a text box like this
ActionScript Code:
var url:String = "dictionaries/"aa.txt";
var loadit:URLLoader = new URLLoader();
loadit.addEventListener(Event.COMPLETE, completeHandler);
[Code]....
how could I randomly choose a word from the list and have it as a variable
Long story short: I want to search a multidimensional array in AS3 for (in this example) the location of 6 strings - all of which are stored in another unrelared array. Long story long: Once I get the locations (in the multidimensional array) of each string, i then know where it's located, and can access other atributes of that object - so if i found the string "box3" is located in element [5] of my multidimensional array, i can now target: multiArray[5][3] to return the 4th item stored (keeping in mind we're starting from 0, so 3 is the 4th position).
I can get this to work once, but I'm trying to set up a for loop based on the length of my basic string storage array - this array holds (in this example) 6 instance name strings - each time my for loop loops, i need to run a search in my multdimensional array for the next consecutive instance name. Then, once I've located all of them (and store the results in a new temporary array) I can dig around in each location for the info I need.
[Code]...
the applicable differences between an ArrayCollection and a Vector in flex? I'm unsure if I should be using one over the other. I saw that Vector is type safe and that makes me feel better, but are there disadvantages?
public var ac:ArrayCollection = new ArrayCollection();
versus
public var vec:Vector.<String> = new Vector.<String>();
In Flex, it's easy to convert the XML to Object and to ArrayCollection by using var decoder:SimpleXMLDecoder = new SimpleXMLDecoder(); decoder.decodeXML( xml );
But is there a good way to convert ArrayCollection to XML.
I currently have an arrayCollection in Flex and I want to sent it to PHP (Zend_AMF). According to the Zend_AMF wiki, sending an arrayCollection over directly will force Zend_AMF to cast the arrayCollection as an object which is no good. I'd rather have an array of my models. I assume the best way would be to convert the arrayCollection to an array in flex and then send it over. Is this true, and if so how would I do that in Flex 3? If you have a better recommendation,
View 1 RepliesIs there any way in Flex where in we can sort an arraycollection based on strings .I have a dataprovider with strings like "Critical" "High" "Medium" "Low" where in I need to sort it in such a way that I need Critical to be displayed on the top and next High , Medium and Low follows.
View 1 Replies