The top-level object of the DOS File Manager UCX component. The CurrentDir and Element methods of this object return the Entry component.
Returns an entry which represents the current working directory.
Object.CurrentDir
Entry.
Read-only.
This example returns an entry that represents the current working directory.
set dosfm = CreateObject("ucx:DOSFileMgr")
set Entry = dosfm.CurrentDir
print("Current directory is: "& Entry.Name)
Determines whether or not the server has a DOS partition.
object.DOSPresent
Boolean.
Read-only.
This example returns TRUE if the server has a DOS partition; otherwise, FALSE.
set dosfm = CreateObject("ucx:DOSFileMgr")
If(dosfm.DOSPresent = TRUE) then
print("A DOS partition is present on the server")
Endif
Returns the full path of the directory that contains the server executable (server.exe).
object.Server
String.
Read-only.
This example returns the full path of the directory that contains the server executable (server.exe).
Set dosfm = CreateObject("ucx:DOSFileMgr")
Print("Path to server files:" & dosfm.Server)
Changes the current directory.
object.ChangeDir(
Dir As String)
Boolean. Returns TRUE if the change is successful; otherwise, FALSE.
This example changes to the c:\user directory.
Set dosfm = CreateObject("ucx:DOSFileMgr")
dosfm.ChangeDir("c:\user")
Copies a file within the DOS file system.
object.Copy(
(srcFileName As String,
dstFileName As String)
Boolean. Returns TRUE if the copy is successful; otherwise, FALSE.
srcFileName and dstFileName files reside on either the DOS file system or the NetWare file system and should be managed by absolute paths.
This example copies autoexec.ncf to the c:\temp directory.
set dosfm = CreateObject("ucx:DOSFileMgr")
dosfm.Copy("c:\nwserver\autoexec.ncf", "c:\temp")
Finds a file or directory by path.
object.FindEntry(
(Path As String)
Entry. Returns the Entry object corresponding to the specified path.
This example returns an entry object corresponding to c:\user.
set dosfm = CreateObject("ucx:DOSFileMgr")
set Entry = dosfm.FindEntry("c:\user")