` Comment on an Icetips Article
Icetips - Templates, Tools & Utilities for Clarion Developers

Templates, Tools and Utilities
for Clarion Developers

Add a comment to an Icetips Article

Please add your comments to this article. Please note that you must provide both a name and a valid email address in order for us to publish your comment. Comments are moderated and are not visible until they have been approved. Spam is never approved!

Your Name:  
Email:  
Header text/Subject:  

Please enter your comment in the box below:

Back to article list   Search Articles     Add Comment     Printer friendly     Direct link  

Par2: Reading Directories
2004-12-20 -- Jason S
 
MyQueue Queue, PRE(MYQ) FullPath string(2000) end AllFiles QUEUE(File:queue),PRE(FIL) !Inherit exact declaration of File:queue END LOC:Path string(2000) LOC:Counter LONG LOC:Inner LONG ! End of "Data Section" CODE ! Start of "Processed Code" ! [Priority 5000] MYQ:FullPath = 'D:\Program Files\' add(MyQueue) LOC:Counter = 0 loop LOC:Counter += 1 get(MyQueue, LOC:Counter) if errorcode() BREAK end LOC:Path = MYQ:FullPath free(AllFiles) DIRECTORY(AllFiles,clip(LOC:Path) & '*.*',ff_:DIRECTORY) LOC:Inner = 0 loop LOC:Inner += 1 get(AllFiles, LOC:Inner) if errorcode() BREAK end IF BAND(FIL:Attrib,ff_:DIRECTORY) AND FIL:ShortName <> '..' AND FIL:ShortName <> '.' MYQ:FullPath = clip(LOC:Path) & clip(FIL:name) & '\' add(MyQueue) end end end


Today is May 2, 2024, 12:59 am
This article has been viewed 35122 times.



Back to article list   Search Articles   Add Comment   Printer friendly

Login

User Name:

Password: