KNOWLEDGE BASE
Log In    |    Knowledge Base    |    4D Home
Tech Tip: Retrieving the name and icon of documents located in a target folder
PRODUCT: 4D | VERSION: | PLATFORM: Mac & Win
Published On: April 17, 2002
Your current browser may not allow you to download the asset. We recommend Mozilla Firefox or Google Chrome.
Log In

The following method allows you to store in a record the name and icon of each document that resides in the selected folder.



C_LONGINT($MaxSize)

C_TEXT($Folder)



$Folder:=Select folder

ARRAY TEXT($ArrDoc;0)

DOCUMENT LIST($Folder;$ArrDoc)



$MaxSize:=Size of array($ArrDoc)

For ($i;1;$MaxSize)



 CREATE RECORD([Table 1])



 [Table 1]Doc:=$ArrDoc{$i}



 GET DOCUMENT ICON($Folder+$ArrDoc{$i};[Table 1]Icon;32)



 SAVE RECORD([Table 1])

End for