does directory exist?

does directory exist?

Postby clemerson » Fri Sep 01, 2006 9:02 pm

Hi,

Which the best form for a directory to be seen exists?

example:
C:\BA

* he doesn't have any file in this directory

Clemerson
User avatar
clemerson
 
Posts: 58
Joined: Fri Mar 10, 2006 8:13 pm
Location: Brazil

Postby George » Fri Sep 01, 2006 9:33 pm

Clemerson

lIsDir(cDirectoryName)

return .T. if exist, else return .F.

Regards


George
George
 
Posts: 725
Joined: Tue Oct 18, 2005 6:49 pm

Postby Silvio » Fri Sep 01, 2006 9:34 pm

see this sample :
I hope it good for you



Code: Select all  Expand view

cIni :=GetWinDir()+"\Classroom.Ini"
cTem :=GetPvProfString("Classroom","DirDat","",cIni)
cDir :=IF(!Empty(cTem),LFN2SFN(cTem),cTem)
cNSys:="ClassRoom"

IF !Empty(cPar) .AND. cPar=="/L"
      cPath:=CurDrive()+":\"+CurDir()+"\"
   ELSE
      cPath:=IF(!Empty(cDir),cDir,"\"+CurDir()+"\")
   ENDIF
   IF Empty(cTem)
      cPath:=CurDrive()+":\"+CurDir()+"\"
      WritePProString(cNSys,"DirDat",cPath,cIni)
   ENDIF
Best Regards, Saludos

Falconi Silvio
User avatar
Silvio
 
Posts: 3107
Joined: Fri Oct 07, 2005 6:28 pm
Location: Teramo,Italy

Postby clemerson » Mon Sep 04, 2006 2:02 pm

tank's

Clemerson
User avatar
clemerson
 
Posts: 58
Joined: Fri Mar 10, 2006 8:13 pm
Location: Brazil


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Otto and 66 guests