Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Namespace is not returning a true directory name
Message
General information
Forum:
Visual FoxPro
Category:
Object Oriented Programming
Miscellaneous
Thread ID:
01235257
Message ID:
01235258
Views:
13
>Namespace is not returning a true directory name. How do I get around this?
>
>
>CLEAR
>
>lcDir = [C:\Documents and Settings\Administrator\My Documents\]
>
>loShell = CreateObject("Shell.Application")
>loFolder = loShell.Namespace( lcDir )
>
>For Each lcFileName in loFolder.Items
>	lcDirName = loFolder.GetDetailsOf(lcFileName, 0)
>	if !directory(lcDirName)
>		?'Dir not found: ' + lcDirName
>	ENDIF
>NEXT 	
>
How about:
CLEAR

lcDir = [C:\Documents and Settings\Administrator\My Documents\]

loShell = CreateObject("Shell.Application")
loFolder = loShell.Namespace( lcDir )

For Each lcFileName in loFolder.Items
    lcDirName = loFolder.GetDetailsOf(lcFileName, 0)

    if !directory(lcDir+lcDirName)
        ?'Dir not found: ' + lcDirName  
    ENDIF 
NEXT
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.
Previous
Reply
Map
View

Click here to load this message in the networking platform