Jump to content

_FileListToArrayByDate()


SmOke_N
 Share

Recommended Posts

  • Moderators

This was a request, it's not overly tested, but it seems to do the trick... You can test it with this:

$Test = _FileListToArrayByDate(@WindowsDir, 'exe', @DeskTopDir & '\StoreFileArray.txt', 1, 1)
If IsArray($Test) Then
    For $i = 1 To UBound($Test) - 1
        MsgBox(0, 'Testing', $Test[$i])
    Next
Else
    MsgBox(0, 'Error', '@error = ' & $Test)
EndIf

Edit

Updated some error checking.

Edit2

Updated Syntax

Edit3

Last Edit (Until the next one): UDF Standard Format

Edited by SmOke_N

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Link to comment
Share on other sites

This was a request, it's not overly tested, but it seems to do the trick... You can test it with this:

$Test = _FileListToArrayByDate(@WindowsDir, '*.exe', @DeskTopDir & '\StoreFileArray.txt', 1, 1)
If IsArray($Test) Then
    For $i = 1 To UBound($Test) - 1
        MsgBox(0, 'Testing', $Test[$i])
    Next
Else
    MsgBox(0, 'Error', '@error = ' & $Test)
EndIf

Edit

Updated some error checking.

i didn't try it out, but looks very nice. when are you going to add recursive sub directory inclusion?
Link to comment
Share on other sites

  • Moderators

i didn't try it out, but looks very nice. when are you going to add recursive sub directory inclusion?

As soon as you write the add-on :)

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...