Sign in to follow this  
Followers 0
marshallprank

Array Content in txt-file

4 posts in this topic

Hi,

i want to log the array content (the names of files and folders) in a txt-file. My code shows me anything in the Log.txt file:

#Include <Array.au3>

$ProgramFilePath = "E:\Programme"

$FileListInFirmware=_FileListToArray($ProgramFilePath & "\Firmware")

_ArrayDisplay($FileListInFirmware)

_FileWriteLog(@ScriptDir & "\Log.txt" , $FileListInFirmware);

Any idee?

Regards

Share this post


Link to post
Share on other sites



#2 ·  Posted (edited)

Have you tried a FOR loop?

For $i = 1 to $FileListInFirmware[0] - 1
    WriteToFile($FileListInFirmware[$i])
Next
Edited by Mallie99

Are you telling me something I need to know or something I want to know?

Share this post


Link to post
Share on other sites

Use _FileWriteFromArray() or define a function like _FileWriteLog() that using write from array.


When the words fail... music speaks

Share this post


Link to post
Share on other sites

thanks its working

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  
Followers 0