Listview
Posted: Tue Jun 01, 2004 1:31 am
Thats the filesystem example :
Ive got a path requester and the listview gadget is showing only the .exe files ....... but know Im trying to create for each exe file a directory.
Example :
file1.exe ------> file1 (directory)
file2.exe ------> file2 (directory)
file3.exe ------> file3 (directory)
but only with filename$ its not workin and i dont know how to use getgadgetitemtext for this problem (and i even dont know if this is the solution for my problem)
Code: Select all
If EventGadgetID() = 1 ; Read
ClearGadgetItemList(2) ; Clear all the items found in the ListView
If ExamineDirectory(0, GetGadgetText(0), "*.*")
Repeat
FileType = NextDirectoryEntry()
If FileType
FileName$ = DirectoryEntryName()
If FileType = 2 ; Directory type
FileName$ = "(DIR) "+FileName$
EndIf
AddGadgetItem(2, -1, FileName$)
EndIf
Until FileType = 0
Else
MessageRequester("Error","Can't examine this directory: "+GetGadgetText(0),0)
EndIf
EndIf
EndIf
Ive got a path requester and the listview gadget is showing only the .exe files ....... but know Im trying to create for each exe file a directory.
Example :
file1.exe ------> file1 (directory)
file2.exe ------> file2 (directory)
file3.exe ------> file3 (directory)
but only with filename$ its not workin and i dont know how to use getgadgetitemtext for this problem (and i even dont know if this is the solution for my problem)