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

  • Home
  • SEARCH
  • 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 3337596
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T00:16:16+00:00 2026-05-18T00:16:16+00:00

I have this function that loads an specific .log file: function loadTracks():void { tracksLoader.load(new

  • 0

I have this function that loads an specific .log file:

function loadTracks():void {
tracksLoader.load(new URLRequest("/Users/Me/127.0.0.1,"+_logNum+".log")); 
}

The logNum variable gets its value, writing it by hand in a separate text file, avoiding to open and editing the .fla each time the new .log has a different name:

logNumLoader.load(new URLRequest("/Users/Me/trackLogNum.txt"));

So this is my question:

Some application creates in each session a new .log file with this file name pattern:

127.0.0.1,NUMBER.log // Being NUMBER the 5 digit changing part of the name, each time a new .log file is created. The newer the file, the higher this value is.

I would like to know how to make this script to autoload the last .log file, as it has the highest value in its name.

I.E.

Having in /Users/ME/

127.0.0.1,12345.log

127.0.0.1,34567.log

127.0.0.1,56789.log

In this case, the script must automatically select and load the 127.0.0.1,56789.log file.

Thank you in advance.

  • 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-18T00:16:17+00:00Added an answer on May 18, 2026 at 12:16 am

    I would use PHP to either identify the latest log by using the filemtime function or by sorting the log files ( following your description , the highest log should come last ).

    Edit:
    This can’t be done in Actionscript 3, unless it’s an Air application. AS3 deals with the client site and accessing files & directories is a server side operation.

    I’m not a PHP guru so , although I could offer a solution that works fine, it would take me more time and might not be as efficient as what some of the PHP stars here could come up with. I would recommend you to either retag your question or simply post a new question asking what script you actually need to sort out your log files.

    When you have the PHP script, look at the following tutorial to see how you can load PHP result into your Flash application. In this example , the script retrieves value from a database, but you should be able to easily adapt this to your context , as long as the script returns content in the form of a name/value pair. It’s all explained in the tutorial 😉
    http://www.flash-db.com/Tutorials/loadingAS3/loadingData.php?page=5

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

No related questions found

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.