Jump to content
Sign in to follow this  
GameIDevelp

_FileListToArray ,,,I can write all File into text file....

Recommended Posts

GameIDevelp

Helloo ,all...

I make this code to write all files after desktop into the desk.text file ... But shee dont work ^_^ , I not have any ideea to do this ... I dont now how ,,, ...Can any help me ,,,to understand how to do this ... ..I appreciate any help ,,,

$FileList2=_FileListToArray(@DesktopDir)
         If @Error=1 Then
          MsgBox (0,"","No Files\Folders Found.")
    Exit
     EndIf        
                
          _FileWriteLog("desk.text",$FileList2)

           If $FileList2[0] >50 Then      
       Box (0,"","More then 50 File...Read desk.text")
       ShellExecute("desk.text")
       Else
     _ArrayDisplay($FileList2,"desk-file= ")
      EndIf

Share this post


Link to post
Share on other sites
Valuater

FileListToArray() creates an $Array, so use FileWriteFromArray()

#include <File.au3>
#include <Array.au3>

$FileList2 = _FileListToArray(@DesktopDir)
If @error = 1 Then
    MsgBox(0, "", "No Files\Folders Found.")
    Exit
EndIf

_FileWriteFromArray("desk.text", $FileList2)

If $FileList2[0] > 50 Then
    MsgBox(0, "", "More then 50 File...Read desk.text")
    ShellExecute("desk.text")
Else
    _ArrayDisplay($FileList2, "desk-file= ")
EndIf

8)

Edited by Valuater

NEWHeader1.png

Share this post


Link to post
Share on other sites
GameIDevelp

I find ,,, wow great ,,, hey Valuater thanks and you ... and for replay .... ..

This is Cod I use ....

For $si =1 to $FileList2[0] Step 1
 _FileWriteLog("desk.text",$FileList2[$si])
 next

Great ... ^_^

Edited by GameIDevelp

Share this post


Link to post
Share on other sites
Valuater

I find ,,, wow great ,,, hey Valuater thanks and you ... and for replay .... ..

This is Cod I use ....

For $si =1 to $FileList2[0] Step 1
  _FileWriteLog("desk.text",$FileList2[$si])
  next

Great ... ^_^

That works too... and Welcome!

8)


NEWHeader1.png

Share this post


Link to post
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
Sign in to follow this  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.