home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
FCE Gold Plus
/
GOLD.iso
/
pc
/
fscommand
/
Xtras
/
FileXtra4_test.dir
/
00012_Script_VolumeTests()
< prev
next >
Wrap
Text File
|
2002-12-20
|
2KB
|
46 lines
on VolumeTests
WriteInfo(RETURN & "Volume Tests commencing")
WriteInfo("******************************************")
fxObj = xtra("FileXtra4").new()
if not(objectP(fxObj)) then
WriteInfo("*** Could not instantiate FileXtra4. Is it in the Xtras folder? ***" & RETURN)
return
end if
volumeList = fxObj.fx_VolumesToList()
WriteInfo("fx_VolumesToList returned the following volumes:")
repeat with i = 1 to volumeList.count
WriteInfo(" " & volumeList.getAt(i))
end repeat
WriteInfo("") -- blank line
repeat with i = 1 to volumeList.count
retVal = fxObj.fx_VolumeExists(volumeList.getAt(i))
WriteInfo(volumeList.getAt(i))
WriteInfo(" fx_VolumeExists('" & volumeList.getAt(i) & "') returns " & GetTrueFalseString(retVal))
WriteInfo(" fx_ErrorNumber returns " & fxObj.fx_ErrorNumber() & ", fx_ErrorString returns '" & fxObj.fx_ErrorString() & "'")
retVal = fxObj.fx_VolumeIsRemovable(volumeList.getAt(i))
WriteInfo(" fx_VolumeIsRemovable('" & volumeList.getAt(i) & "') returns " & GetTrueFalseString(retVal))
WriteInfo(" fx_ErrorNumber returns " & fxObj.fx_ErrorNumber() & ", fx_ErrorString returns '" & fxObj.fx_ErrorString() & "'")
retVal = fxObj.fx_VolumeIsCDROM(volumeList.getAt(i))
WriteInfo(" fx_VolumeIsCDROM('" & volumeList.getAt(i) & "') returns " & GetTrueFalseString(retVal))
WriteInfo(" fx_ErrorNumber returns " & fxObj.fx_ErrorNumber() & ", fx_ErrorString returns '" & fxObj.fx_ErrorString() & "'")
totBytes = fxObj.fx_VolumeGetTotalBytes(volumeList.getAt(i))
WriteInfo(" fx_VolumeGetTotalBytes('" & volumeList.getAt(i) & "') returns " & totBytes)
WriteInfo(" fx_ErrorNumber returns " & fxObj.fx_ErrorNumber() & ", fx_ErrorString returns '" & fxObj.fx_ErrorString() & "'")
freeBytes = fxObj.fx_VolumeGetFreeBytes(volumeList.getAt(i))
WriteInfo(" fx_VolumeGetFreeBytes('" & volumeList.getAt(i) & "') returns " & freeBytes)
WriteInfo(" fx_ErrorNumber returns " & fxObj.fx_ErrorNumber() & ", fx_ErrorString returns '" & fxObj.fx_ErrorString() & "'")
WriteInfo("")
end repeat
fxObj = 0
end