Skip to main content
Question

get tree of file and subfolder display in txt file_

  • February 2, 2024
  • 6 replies
  • 133 views

Forum|alt.badge.img+4

Hello everybody,

I try to get all folder, subfolder name and file mane, type in output file.

the output must display like a tree.

EX content of C:

C\

     B\B1\T.txt

      D\H.pdf

 

Output: file.txt

C

     B

          B1

                T.txt(txt)        

     D   

          H.pdf(pdf)

 

I thank you for your very valuable help.

6 replies

Tamil Arasu10
Most Valuable Pathfinder
Forum|alt.badge.img+18
  • Most Valuable Pathfinder
  • February 2, 2024

Hi @Olatidoye ,

 

Please find the below,

You can get the Folder and Subfolder names by select Include all sub folder option.

Once you have get subfolder path, (pass the path location into another loop) 

add Loop For Each file in Folder for the getting the filename

 

Note : Include the if condition for validate the file extensions

 

 
 

Forum|alt.badge.img+4
  • Author
  • Navigator | Tier 3
  • February 2, 2024

Thank for your reply . please can you show step by step in order to follow you 


Tamil Arasu10
Most Valuable Pathfinder
Forum|alt.badge.img+18
  • Most Valuable Pathfinder
  • February 3, 2024

 


Forum|alt.badge.img+4
  • Author
  • Navigator | Tier 3
  • February 3, 2024

hello ,

when i run i get this error message

 


Forum|alt.badge.img+4
  • Author
  • Navigator | Tier 3
  • February 3, 2024

This is the code on AA360

 

 


Tamil Arasu10
Most Valuable Pathfinder
Forum|alt.badge.img+18
  • Most Valuable Pathfinder
  • February 5, 2024

have you selected the 1st loop, like a below