home *** CD-ROM | disk | FTP | other *** search
Wrap
'NWFILE.BAS NetWare File Services Interface for Visual Basic For Windows 'Version 1.0 'Novell Systems Research Department, Novell, Inc. 'Copyright (c) 1993, Novell, Inc. 'This interface is not supported through Novell's regular 'support channels. See README.TXT for more information. 'File attributes Global Const FA_NORMAL = &H0 Global Const FA_READ_ONLY = &H1 Global Const FA_HIDDEN = &H2 Global Const FA_SYSTEM = &H4 Global Const FA_EXECUTE_ONLY = &H8 Global Const FA_DIRECTORY = &H10 Global Const FA_ARCHIVE = &H20 Global Const FA_SHARABLE = &H80 'Extended file attributes Global Const FA_TRANSACTIONAL = &H10 Global Const FA_INDEXED = &H20 Global Const FA_READ_AUDIT = &H40 Global Const FA_WRITE_AUDIT = &H80 'Type NWFILE_ENTRY declared in Directory Services section Type FORK_SIZE logical As Long physical As Long End Type Type NWPHYS_ENTRY sequence As Long reserved1 As Long attributes As Long reserved2 As Integer NSType As String * 1 nameLength As String * 1 name As String * 12 creationDate As Integer creationTime As Integer ownerID As Long lastArchivedDate As Integer lastArchivedTime As Integer lastArchiverID As Long modifyDate As Integer modifyTime As Integer lastModifierID As Long dataForkSize As Long reserved3 As String * 44 inheritedRightsMask As Integer lastAccessDate As Integer reserved4 As String * 28 forkSize1 As FORK_SIZE forkSize2 As FORK_SIZE forkSize3 As FORK_SIZE forkSize4 As FORK_SIZE forkSize5 As FORK_SIZE End Type Type NWSALV_ENTRY entryID As Long attributes As Long nameSpaceType As String * 1 nameLength As String * 1 name As String * 12 lastArchiveDateAndTime As Long lastArchiverID As Long modifyDateAndTime As Long lastModifierID As Long dataForkSize As Long lastAccessedDate As Integer deletedFileTime As Long deletedDateAndTime As Long deletorID As Long End Type Declare Function EraseFiles Lib "NWNETAPI.DLL" (ByVal dirHandle%, ByVal filePath$, ByVal searchAttributes%) As Integer Declare Function FileServerFileCopy Lib "NWNETAPI.DLL" (ByVal sourceFileHandle%, ByVal destFileHandle%, ByVal sourceFileOffset&, ByVal destFileOffset&, ByVal bytesToCopy&, bytesCopied&) As Integer Declare Function GetExtendedFileAttributes Lib "NWNETAPI.DLL" (ByVal filePath$, extendedFileAttrib%) As Integer Declare Function PurgeAllErasedFiles Lib "NWNETAPI.DLL" () As Integer '2.x only Declare Function PurgeErasedFiles Lib "NWNETAPI.DLL" () As Integer '2.x only Declare Function PurgeSalvagableFile Lib "NWNETAPI.DLL" (ByVal serverConnID%, ByVal dirHandle%, entryID&, ByVal fileName$) As Integer '3.x/4.x only Declare Function RecoverSalvagableFile Lib "NWNETAPI.DLL" (ByVal serverConnID%, ByVal dirHandle%, ByVal entryID&, ByVal fileName$, ByVal newName$) As Integer '3.x/4.x only 'erasedFileName and restoredFileName must be initialized to 13 characters Declare Function RestoreErasedFile Lib "NWNETAPI.DLL" (ByVal dirHandle%, ByVal volName$, ByVal erasedFileName$, ByVal restoredFileName$) As Integer '2.x only Declare Function ScanFileEntry Lib "NWNETAPI.DLL" (ByVal serverConnID%, ByVal dirHandle%, ByVal searchPath$, ByVal searchAttrib%, sequence&, fileEntry As NWFILE_ENTRY) As Integer '3.x/4.x only 'fileName must be initialized to 15 bytes Declare Function ScanFileInformation Lib "NWNETAPI.DLL" (ByVal dirHndl%, ByVal path$, ByVal srchAttrib%, seq%, ByVal fileName$, attrib%, extAttrib%, size&, creat%, lastAcc%, updated&, archived&, owner&) As Integer Declare Function ScanFilePhysical Lib "NWNETAPI.DLL" (ByVal serverConnID%, ByVal dirHandle%, ByVal searchPath$, ByVal searchAttrib%, sequence&, fileEntry As NWPHYS_ENTRY) As Integer '3.x/4.x only Declare Function ScanSalvagableFiles Lib "NWNETAPI.DLL" (ByVal serverConnID%, ByVal dirHandle%, entryID&, salvEntry As NWSALV_ENTRY) As Integer '3.x/4.x only Declare Function SetExtendedFileAttributes Lib "NWNETAPI.DLL" (ByVal filePath$, ByVal extFileAttrib%) As Integer Declare Function SetFileInformation Lib "NWNETAPI.DLL" (ByVal dirHndl%, ByVal path$, ByVal searchAttrib%, ByVal attrib%, ByVal extAttrib%, ByVal created%, ByVal lastAcc%, ByVal updated&, ByVal archived&, ByVal owner&) As Integer