18 lines
670 B
Text
18 lines
670 B
Text
Module ExistDirAndFile {
|
|
Let WorkingDir$=Dir$, RootDir$="C:\"
|
|
|
|
task(WorkingDir$)
|
|
task(RootDir$)
|
|
Dir User ' return to user directroy
|
|
|
|
Sub task(WorkingDir$)
|
|
Local counter
|
|
Dir WorkingDir$
|
|
If Not Exist.Dir("docs") then Report "docs not exist in "+WorkingDir$ : counter++
|
|
If Not Exist("output.txt") Then {
|
|
Report "output.txt not exist in "+ WorkingDir$ : counter++
|
|
} Else.if Filelen("output.txt")=0 Then Report "output.txt has zero length"
|
|
If counter =0 then Report WorkingDir$+ " has docs directory and file output.txt"
|
|
End Sub
|
|
}
|
|
ExistDirAndFile
|