Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7635863
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T07:31:58+00:00 2026-05-31T07:31:58+00:00

I’ve got a properties file with two distinct key-value pair patters like the following;

  • 0

I’ve got a properties file with two distinct key-value pair patters like the following;

  1. name.name.name.key = value
  2. name.name.fullname.key = value

Accessing them one by one is fine if the key is known.
What I need now, though, is to access ALL values from say name.name.name without knowing the keys (integers to be exact). The values then have to be added to an ArrayList to be displayed in a List.

The keys are completely random, so I don’t know the range beforehand (I can’t and don’t want to hardcode the range of range of keys for each single properties file), so simply looping through a previously defined range isn’t what I need here. Also, the keys are not successive.

How can I do this with AS3?

Just for clarification as this seems to be a little confusing;
I do not want to parse the properties file. I rather want to solve this using the methods AS and Flex already provide.
The ResourceBundle class already has a method that outputs the content of the specified bundle. However, it contains all values. What I need is just a subset of values that match a given key pattern.

Edit:
To make this easier, I can drop the key pattern matching and create a new resource file with a distinct pattern. Now I only need to get all key-value pairs (I need both the integers from the keys and the value) from that resource.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T07:31:59+00:00Added an answer on May 31, 2026 at 7:31 am

    Here is a simple example with string parsing:

    import flash.net.URLLoader;
    import flash.net.URLRequest;
    import flash.events.Event;
    
    var l:URLLoader = new URLLoader(new URLRequest("inp.txt"));
    l.addEventListener(Event.COMPLETE, onComplete);
    
    
    function onComplete(e:Event):void
    {
        var data:String = e.target.data;
            //remove whitespace
        data = data.replace(' ','');
            //split data string by lines
        var pairs:Array = data.split("\r\n");
            //our name search pattern
        var pattern:RegExp = /name\.name\.name/;
            //array to store extracted values
        var values:Array = [];
        for each (var s:String in pairs) {
            if (pattern.test(s)) {
                //we've got a match, let's extract value
                var value:String = s.split("=")[1];
                values.push(value);
            }
        }
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've got a string that has curly quotes in it. I'd like to replace
I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
I am trying to render a haml file in a javascript response like so:
I have just tried to save a simple *.rtf file with some websites and
link Im having trouble converting the html entites into html characters, (&# 8217;) i
I would like to count the length of a string with PHP. The string
For some reason, after submitting a string like this Jack’s Spindle from a text
I want use html5's new tag to play a wav file (currently only supported
I'm using v2.0 of ClassTextile.php, with the following call: $testimonial_text = $textile->TextileRestricted($_POST['testimonial']); ... and
In my XML file chapters tag has more chapter tag.i need to display chapters

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.