>>SABDU001 ------------------ SABDU001.DLL API: OverView ------------------------ Dynamic Load Library Routines The SABDU001 Dynameic Load Library contains a set of routines for creating and manipulating diskette type objects. The sets of routines are: DiskDrive This are the ones that are usually used. They operate at the logical level. DDrive Drive object FDrive File object MDrive Memory object VDrive Virtual object DebugOut Debugging routines HandleStatus Callback routine used to communicate progress during long running operations (i.e. formatting a diskette) and status. >>DDrive ------------------ SABDU001.DLL API: DDrive objects ------------------ A DDrive (Diskette Drive) is a specialized version of the VDrive (Virtual Drive). It is an object that represents a physical drive. The following functions are available to manipulate it: DDriveCreate Creates a DDrive object DDriveDelete Deletes a DDrive object DDriveFormatTrack Formats a track DDriveForceReset Issues a reset to the drive DDriveReadSectors Reads a group of sectors from the drive DDriveReset Issues a reset to the drive if it was used DDriveSetRead Sets up for reading from the drive DDriveSetWrite Sets up for writing to the drive DDriveWriteSectors Writes a group of sectors to the drive >>DDriveCreate ------------------ SABDU001.DLL API: DDriveCreate -------------------- VOID far * FAR PASCAL DDriveCreate ( char cDrive, lpfnHANDLESTATUS lpfnNewHandleStatus ) cDrive The letter of the drive. lpfnNewHandleStatus Points to a callback routine that handles event notifications including errors. Creates a DDrive object associated with drive cDrive. Returns: Pointer to DDrive object. Example: VOID far *pDriveA ; pDriveA = DDriveCreate ( 'A', lpfnHandleStatus ) ; >>DDriveDelete ------------------ SABDU001.DLL API: DDriveDelete -------------------- VOID FAR PASCAL DDriveDelete ( pDDrive ) pDDrive Points to DDrive object to be deleted. Deletes the DDrive object pointed to by pDDrive. Returns: VOID Example: VOID far *pDriveA ; pDriveA = DDriveCreate ( 'A', lpfnHandleStatus ) ; ... DDriveDelete ( pDriveA ) ; pDriveA = NULL ; >>DDriveSetRead ------------------ SABDU001.DLL API: DDriveSetRead ------------------- UINT FAR PASCAL DDriveSetRead ( VOID far *pDDrive, UINT nTempType, UINT nCylinders ) pDDrive Points to the DDrive object. nTempType Defines the type of diskette expected: FD0360 FD0720 FD1200 FD1440 FD2880 nCylinders Defines the number of cylinders. NULL indicates default for type. Prepares the DDrive object pointed to by pDDrive for reading. Returns: zero if successfull, status code if not successfull. Example: VOID far *pDriveA ; pDriveA = DDriveCreate ( 'A', lpfnHandleStatus ) ; ... DDriveSetRead ( pDriveA, FD0360, NULL ) ; >>DDriveSetWrite ------------------ SABDU001.DLL API: DDriveSetWrite ------------------ UINT FAR PASCAL DDriveSetWrite ( VOID far *pDDrive, UINT nTempType, UINT nCylinders ) pDDrive Points to the DDrive object. nTempType Defines the type of diskette expected: FD0360 FD0720 FD1200 FD1440 FD2880 nCylinders Defines the number of cylinders. NULL indicates default for type. Prepares the DDrive object pointed to by pDDrive for writing. Returns: zero if successfull, status code if not successfull. Example: VOID far *pDriveA ; pDriveA = DDriveCreate ( 'A', lpfnHandleStatus ) ; ... DDriveSetWrite ( pDriveA, FD0360, NULL ) ; >>DDriveReset ------------------ SABDU001.DLL API: DDriveReset --------------------- UINT FAR PASCAL DDriveReset ( VOID far *pDDrive ) pDDrive Points to the DDrive object. Resets the DDrive object pointed to by pDDrive. Returns: zero if successfull, status code if not successfull Example: VOID far *pDriveA ; pDriveA = DDriveCreate ( 'A' ) ; ... DDriveReset ( pDriveA ) ; >>DDriveForceReset ------------------ SABDU001.DLL API: DDriveForceReset ---------------- UINT FAR PASCAL DDriveForceReset ( VOID far *pDDrive ) pDDrive Points to DDrive object. Resets the DDrive object pointed to by pDDrive. Returns: zero if successfull, status code if not successfull. Example: VOID far *pDriveA ; pDriveA = DDriveCreate ( 'A', lpfnHandleStatus ) ; ... DDriveForceReset ( pDriveA ) ; >>DDriveFormatTrack ------------------ SABDU001.DLL API: DDriveFormatTrack --------------- UINT FAR PASCAL DDriveForceReset ( VOID far *pDDrive, UNIT nCylinder, UNIT nHead ) pDDrive Points to DDrive Object nCylinder Number of Cylinder to be formatted nHead Number of Head to be formatted Formats a track. Returns: zero if successfull, status code if not successfull Example: VOID far *pDriveA ; pDriveA = DDriveCreate ( 'A', lpfnHandleStatus ) ; ... DDriveFormatTrack ( pDriveA, nCylinder, nHead ) ; >>DDriveReadSectors ------------------ SABDU001.DLL API: DDriveReadSectors --------------- UINT FAR PASCAL DDriveReadSectors ( VOID far *pDDrive, UNIT nCylinder, UNIT nHead, UINT nSector, UINT nCount, LPBYTE lpcBuffer ) pDDRive Points to DDrive object. nCylinder Cylinder to read from nHead Head to read with nSector Starting sector nCount Number of sectors to read lpcBuffer Buffer to contain the data read. Reads a group of sectors. Returns: zero if successfull, status code if not successfull. Example: VOID far *pDriveA ; pDriveA = DDriveCreate ( 'A', lpfnHandleStatus ) ; ... DDriveReadSectors ( pDriveA, nCylinder, nHead, nSector, nCount, lpcBuffer ) ; >>DDriveWriteSectors ------------------ SABDU001.DLL API: DDriveWriteSectors -------------- UINT FAR PASCAL DDriveWriteSectors ( VOID far *pDDrive, UNIT nCylinder, UNIT nHead, UINT nSector, UINT nCount, LPBYTE lpcBuffer ) pDDrive Points to DDrive object. nCylinder Cylinder to write to nHead Head to write with nSector Starting sector nCount Number of sectors to write lpcBuffer Buffer that contains the data to be written. Writes a group of sectors from the drive pointerd to by pDDrive Returns: zero if successfull, status code if not successfull. Example: VOID far *pDriveA ; pDriveA = DDriveCreate ( 'A' ) ; ... DDriveWriteSectors ( pDriveA, nCylinder, nHead, nSector, nCount, lpcBuffer ) ; >>DebugOut ------------------ SABDU001.DLL API: DebugOut objects ---------------- A DebugOut object is a debugging aid: The following functions are available to manipulate it: DebugOutCreate Creates debug object DebugOutOutputIf Outputs a message DebugOutScan Scans command line for control information DebugOutczDebugBuffer Returns pointer to debug buffer >>DebugOutCreate ------------------ SABDU001.DLL API: DebugOutCreate ------------------ VOID far * FAR PASCAL CEXPORT DebugOutCreate ( LPCSTR lpczCmdLine ) ; Command line: [/Dxxxxxxxx [/Myyyyyyyy] [/Ffilename]] xxxxxxxx is a hex string each bit of which can be used to control the sending of trace messages yyyyyyyy is a hex string each bit of which indicates if a control message should be displayed in a MessageBox filename trace file name Returns: Pointer to a debug object. >>DebugOutScan ------------------ SABDU001.DLL API: DebugOutScan -------------------- VOID FAR PASCAL CEXPORT DebugOutScan ( LPCSTR lpczCmdLine ) ; Command line: [/Dxxxxxxxx [/Myyyyyyyy] [/Ffilename]] xxxxxxxx is a hex string each bit of which can be used to control the sending of trace messages yyyyyyyy is a hex string each bit of which indicates if a control message should be displayed in a MessageBox filename trace file name Returns: VOID >>DebugOutOutputIf ------------------ SABDU001.DLL API: DebugOutOutputIf ---------------- VOID FAR PASCAL CEXPORT DebugOutOutputIf ( unsigned long ulDFlag, LPCSTR lpczText, LPCSTR lpczTitle, UINT nMFlags ) ; ulDFlag Matched with /D and /M from command line to determine if message should be output to trace or displayed in a MessageBox. lpczText Pointer to text of trace message lpczTitle Pointer to title of trace message nMFlags MessageBox flags Displays a MessageBox or writes a trace record. Returns: VOID >>DebugOutczDebugBuffer ------------------ SABDU001.DLL API: DebugOutczDebugBuffer ----------- char far * FAR PASCAL CEXPORT DebugOutczDebugBuffer ( VOID ) ; Returns: Pointer to debug buffer that can be used to format messages. >>DebugOutDebugFlags ------------------ SABDU001.DLL API: DebugOutczDebugBuffer ----------- char far * FAR PASCAL CEXPORT DebugOutDebugFlags ( VOID ) ; Returns debug flags. >>DiskDrive ------------------ SABDU001.DLL API: DiskDrive objects --------------- A DiskDrive is a wrapper that encapsolates a virtual (VDrive) object and provides all of the functions needed to manipulate it The following functions are available to manipulate it: DiskDriveChangeCurrentDirectory Changes the current directory DiskDriveCompare Compares two DiskDrive objects DiskDriveCopy Copies a DiskDrive object DiskDriveConvert Converts a DiskDrive object DiskDriveCreateDrive Creates a DiskDrive object DiskDriveCreateFile Creates a DiskDrive object DiskDriveCreateMemory Creates a DiskDrive object DiskDriveCreateVDrive Creates a DiskDrive object DiskDriveDelete Deletes a DiskDrive object DiskDriveForceReset Forces a reset of the assocated VDrive DiskDriveFormat Formats a DiskDrive object DiskDriveFormatTrack Formats a track DiskDriveGetAllocatedSectors Returns number of allocated sectors DiskDriveGetCurrentDirectory Returns current directory in argument DiskDriveGetRootDirectory Reads the root directory DiskDriveGetFileAllocationTable Reads a file allocation table DiskDriveGetVolumeDate Gets the volume date DiskDriveGetVolumeLabel Gets the volume label DiskDriveChangeCurrentDirectory Changes the current directory DiskDriveHasData Returns TRUE if object valid DiskDriveHasError Returns TRUE if object has an error DiskDriveIsTruncated Returns TRUE if object is truncated DiskDriveLetter Returns DiskDrive object letter DiskDriveNumberOfFATs Returns the number of FATs DiskDrivePutRootDirectory Writes the root directory DiskDrivePutFileAllocationTable Writes a file allocation table DiskDriveReadClusters Reads a group of clusters from DiskDrive DiskDriveReadSectors Reads a group of sectors from DiskDrive DiskDriveReset Resets the associated VDrive if used DiskDriveRootDirectoryEntries Returns the number of entries in the root DiskDriveSDU_FindFirst Finds the first file that matches specs DiskDriveSDU_FindNext Finds the next file that matches specs DiskDriveSectorsPerCluster Retruns the number of sectors in a cluster DiskDriveSectorsPerFAT Returns the number of sectors in a FAT DiskDriveSetRead Sets the associated VDrive for reading DiskDriveSetType Sets the type (density) of VDrive DiskDriveSetVolumeLabel Sets the volume label DiskDriveSetWrite Sets the associated VDrive for writing DiskDriveSetWriteFormatOption Turns on/off WriteFormatOption DiskDriveSetWriteVerifyOption Turns on/off WriteVerifyOption DiskDriveTruncate Sets truncation mode on DiskDriveTruncateReverse Sets truncation mode off DiskDriveType Returns type (density) DiskDriveUsedCylinders Returns cylinders used DiskDriveUsedHeads Returns heads used DiskDriveUsedSectorSize Returns sector size DiskDriveUsedSectors Returns sectors used DiskDriveWriteBootSector Writes boot sector of DiskDrive DiskDriveWriteClusters Writes a group of clusters to DiskDrive DiskDriveWriteSectors Writes a group of sectors to DiskDrive >>DiskDriveCreateDrive ------------------ SABDU001.DLL API: DiskDriveCreateDrive ------------ UINT FAR PASCAL DiskDriveCreateDrive ( char cDrive UINT nType, UINT nCylinders, lpfnHANDLESTATUS lpfnNewHandleStatus ) cDrive Letter of drive. nType Defines the type of diskette FD0360 FD0720 FD1200 FD1200H FD1440 FD1440H FD2880 nCylinders Number of cylinders NULL indicates default for type lpfnNewHandleStatus Pointer to routine to handle status callbacks Creates a DiskDrive object using a physical drive as the base for the VDrive object within it. Returns: Pointer to DiskDrive object. Example: VOID far *pDiskDriveA ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pDiskDriveA = DiskDriveCreateDrive ( 'A', FD1200, 80, lpfnNewHandleStatus ) >>DiskDriveCreateMemory ------------------ SABDU001.DLL API: DiskDriveCreateMemory ----------- UINT FAR PASCAL DiskDriveCreateMemory ( UINT nMemory UINT nType, UINT nCylinders, lpfnHANDLESTATUS lpfnNewHandleStatus ) nMemory Identifier for DiskDrive memory object nType Defines the type of diskette FD0360 FD0720 FD1200 FD1200H FD1440 FD1440H FD2880 nCylinders Number of cylinders NULL indicates default for type lpfnNewHandleStatus Pointer to routine to handle status callbacks Creates a DiskDrive object using a memory object as the base for the VDrive object within it. Returns: Pointer to DiskDrive memory object. Example: VOID far *pDiskDriveA ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pDiskDriveA = DiskDriveCreateMemory ( 1, FD1200, 80, lpfnNewHandleStatus ) >>DiskDriveCreateFile ------------------ SABDU001.DLL API: DiskDriveCreateFile ------------- UINT FAR PASCAL DiskDriveCreateFile ( LPCSTR lpczFileName, LPCSTR lpczApplicationTitle, LPCSTR lpczVersion, UINT nType, UINT nCylinders, lpfnHANDLESTATUS lpfnNewHandleStatus ) lpczFileName Points to name of file to be used lpczApplicationTitle Points to the application title lpczVersion Points to the version nType Defines the type of diskette FD0360 FD0720 FD1200 FD1200H FD1440 FD1440H FD2880 nCylinders Number of cylinders NULL indicates default for type lpfnNewHandleStatus Pointer to routine to handle status callbacks Creates a DiskDrive object using a file object as the base for the VDrive object within it. Returns: Pointer to DiskDrive file object. Example: VOID far *pDiskDriveA ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pDiskDriveA = DiskDriveCreateFile ( "FileName.SDU", "SAB Diskette Utility", "2.00", FD1200, 80, lpfnNewHandleStatus ) >>DiskDriveCreateVDrive ------------------ SABDU001.DLL API: DiskDriveCreateVDrive ----------- UINT FAR PASCAL DiskDriveCreateVDrive ( VOID far * pVDrive, UINT nType, UINT nCylinders, lpfnHANDLESTATUS lpfnNewHandleStatus ) pVDrive Pointer to VDrive object. nType Defines the type of diskette FD0360 FD0720 FD1200 FD1200H FD1440 FD1440H FD2880 nCylinders Number of cylinders NULL indicates default for type lpfnNewHandleStatus Pointer to routine to handle status callbacks Creates a DiskDrive object using a virtual drive object as the base for the VDrive object within it. Returns: Pointer to DiskDrive object. Example: VOID far *pDiskDriveA ; VOID far *pVDriveA ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pVDriveA = DDriveDrive ( 'A', lpfnNewHandleStatus ) ; pDiskDriveA = DiskDriveCreateVDrive ( pVDriveA, FD1200, 80, lpfnNewHandleStatus ) >>DiskDriveDelete ------------------ SABDU001.DLL API: DiskDriveDelete ----------------- VOID FAR PASCAL DiskDriveDelete ( VOID far * pCDiskDrive, ) pCDiskDrive Pointer to the DiskDrive object to be deleted. Deletes a DiskDrive object. Returns: VOID Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DDriveDriveCreateDrive ( 'A', lpfnNewHandleStatus ) ; ... DiskDriveDelete ( pCDiskDriveA ) ; pCDiskDriveA = NULL ; >>DiskDriveCopy ------------------ SABDU001.DLL API: DiskDriveCopy ------------------- VOID FAR PASCAL DiskDriveCopy ( VOID far * pCDiskDriveTarget, VOID far * pCDiskDriveSource ) pCDiskDriveTarget Points to DiskDrive object to be copied to. pCDiskDriveSource Points to DiskDrive object to be copied from. Copies a DiskDrive object ; Returns: VOID Example: VOID far *pCDiskDriveA ; VOID far *pCDiskDriveB ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; pCDiskDriveB = DiskDriveCreateDrive ( 'B', DiskDriveType( pDiskDriveA ), 0, lpfnNewHandleStatus ) ; DiskDriveCopy ( pCDiskDriveB, pCDiskDriveA ) ; >>DiskDriveCompare ------------------ SABDU001.DLL API: DiskDriveCompare ---------------- BOOL FAR PASCAL DiskDriveCompare ( VOID far * pCDiskDriveTarget, VOID far * pCDiskDriveSource ) pCDiskDriveTarget Points to DiskDrive object. pCDiskDriveSource Points to DiskDrive object. Compares two DiskDrive objects. Returns: TRUE if they are the same -- FALSE if not. Example: VOID far *pCDiskDriveA ; VOID far *pCDiskDriveB ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; pCDiskDriveB = DiskDriveCreateDrive ( 'B', 0, 0, lpfnNewHandleStatus ) ; DiskDriveCompare ( pCDiskDriveB, pCDiskDriveA ) ; >>DiskDriveConvert ------------------ SABDU001.DLL API: DiskDriveConvert ---------------- BOOL FAR PASCAL DiskDriveConvert ( VOID far * pCDiskDriveTarget, VOID far * pCDiskDriveSource ) pCDiskDriveTarget Points to DiskDrive object to contain converted image pCDiskDriveSource Points to DiskDrive object to be converted Converts a DiskDrive object ; Returns: zero if successfull, non-zero if not successfull. Example: VOID far *pCDiskDriveA ; VOID far *pCDiskDriveB ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; pCDiskDriveB = DiskDriveCreateDrive ( 'B', 0, 0, lpfnNewHandleStatus ) ; DiskDriveConvert ( pCDiskDriveB, pCDiskDriveA ) ; >>DiskDriveDeleteFile ------------------ SABDU001.DLL API: DiskDriveDeleteFile ------------- UINT FAR PASCAL DiskDriveDeleteFile ( VOID far * pCDiskDrive, LPCSTR lpczFileName ) pCDiskDrive Points to DiskDrive object. lpczFileName Name of file (including path) to be deleted. Deletes a file from a diskette image. Returns: zero if successfull, non-zero if not successfull Example: VOID far *pCDiskDriveA ; char czFileName[] = "\directory\file.ext" pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; DiskDriveDeleteFile ( pCDiskDriveA, czFileName ) ; >>DiskDriveCopyFile ------------------ SABDU001.DLL API: DiskDriveCopyFile --------------- UINT FAR PASCAL DiskDriveCopyFile ( VOID far * pCDiskDriveTarget, LPCSTR lpczFileNameIn, LPCSTR lpczFileNameOut, UINT Flags ) pCDiskDriveTarget Pointer to DiskDrive object lpczFileNameIn Pointer to file name (including path) lpczFileNameOut Pointer to file name (including path) Flags Copy direction -- must be 1 Copies a file Returns: zero if successfull, non-zero if copy failed Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; DiskDrivecopyFile ( pCDiskDriveA, "OLDFILE.DAT", "C:\DATA\NEWFILE.DAT", IMAGETOFILE ) ; >>DiskDriveSDU_FindFirst ------------------ SABDU001.DLL API: DiskDriveSDU_FindFirst ---------- BOOL FAR PASCAL DiskDriveSDU_FindFirst ( VOID far *pCDiskImage, LPCSTR lpczFileMask, UINT Flags, LPSDU_find_t lpstFind_T ) pCDiskImage Pointer to DiskDrive object. lpczFileMask Pointer to file mask (may include * and ?) Flags Attributes lpstFind_T Pointer to SDU_find_t structure Finds the first file based on file mask and attributes Returns: zero if succesfull, non-zero if file not found Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; char czFileMask[] = "\SUBDIR\FILENAME.EXT" ; UINT Flags = ATTR_READONLY ; SDU_find_t Find_T ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; DiskDriveSDU_FindFirst ( pCDiskDriveA, lpczFileMask, Flags, &Find_T ) ; >>DiskDriveSDU_FindNext ------------------ SABDU001.DLL API: DiskDriveSDU_FindNext ---------- BOOL FAR PASCAL DiskDriveSDU_FindNext ( VOID far *pCDiskImage, LPSDU_find_t lpstFind_T ) pCDiskImage Pointer to DiskDrive object. lpstFind_T Pointer to SDU_find_t structure Finds the next file based on file mask in lpstFind_T Returns: zero if successfull, non-zero if not successfull Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; SDU_find_t Find_T ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; ... DiskDriveSDU_FindNext ( pCDiskDriveA, &Find_T ) ; >>DiskDriveGetCurrentDirectory ------------------ SABDU001.DLL API: DiskDriveGetCurrentDirectory ---- BOOL FAR PASCAL DiskDriveGetCurrentDirectory ( VOID far *pCDiskImage, LPCSTR lpczOldCurrentDirectory ) pCDiskImage Pointer to DiskDrive object. lpczOldCurrentDirectory Pointer to buffer area that will get directory path Gets the current directory path. Returns: lpczOldCurrentDirectory Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; char czCurrentDirectory[_MAX_PATH] char *lpczOldCurrentDirectory ; lpczOldCurrentDirectory = czCurrentDirectory ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; DiskDriveGetCurrentDirectory ( pCDiskDriveA, lpczOldCurrentDirectory ) ; >>DiskDriveChangeCurrentDirectory ------------------ SABDU001.DLL API: DiskDriveChangeCurrentDirectory - BOOL FAR PASCAL DiskDriveChangeCurrentDirectory ( VOID far *pCDiskImage, LPCSTR lpczNewCurrentDirectory ) pCDiskImage Pointer to DiskDrive object. lpczNewCurrentDirectory Pointer to new current directory. Changes the current directory. Returns: lpczNewCurrentDirectory Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; char czCurrentDirectory[] = "\NEW\CURRENT\DIRECTORY" ; char *lpczNewCurrentDirectory ; lpczNewCurrentDirectory = czCurrentDirectory ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; DiskDriveChangeCurrentDirectory ( pCDiskDriveA, lpczNewCurrentDirectory ) ; >>DiskDriveFormatTrack ------------------ SABDU001.DLL API: DiskDriveFormatTrack ------------ UINT FAR PASCAL DiskDriveFormatTrack ( VOID far * pCDiskDrive, UINT nCylinder, UINT nHead, lpfnHANDLESTATUS lpfnHandleStatus ) pCDiskDrive Pointer to DiskDrive object. nCylinder Cylinder number nHead Head number lpfnNewHandleStatus Pointer to routine to handle status callbacks Formats a track. Returns: zero if successfull, status code if not successfull Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', FD1200, 80, lpfnNewHandleStatus ) ; DiskDriveFormatTrack ( pCDiskDriveB, 0, 1, lpfnNewHandleStatus ) ; >>DiskDriveReadClusters ------------------ SABDU001.DLL API: DiskDriveReadClusters ----------- UINT FAR PASCAL DiskDriveReadClusters ( VOID far * pCDiskDrive, UINT nCluster, UINT nCount, LPBYTE lpbyBuffer, lpfnHANDLESTATUS lpfnHandleStatus ) pCDiskDrive Pointer to DiskDrive object. nCluster Starting cluster number. nCount Number of clusters to read. lpfnNewHandleStatus Pointer to routine to handle status callbacks Reads a group of clusters. Returns: zero if successfull, status code if not successfull Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; DiskDriveReadClusters ( pCDiskDriveA, 1, 1, lpcBuffer, lpfnNewHandleStatus ) ; >>DiskDriveWriteClusters ------------------ SABDU001.DLL API: DiskDriveWriteClusters ---------- UINT FAR PASCAL DiskDriveWriteClusters ( VOID far * pCDiskDrive, UINT nCluster, UINT nCount, LPBYTE lpbyBuffer, lpfnHANDLESTATUS lpfnHandleStatus ) pCDiskDrive Pointer to DiskDrive object. nCluster Starting cluster number. nCount Number of clusters to write. lpfnNewHandleStatus Pointer to routine to handle status callbacks Writes a group of clusters. Returns: zero if successfull, status code if not successfull Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; DiskDriveWriteClusters ( pCDiskDriveA, 1, 1, lpcBuffer, lpfnNewHandleStatus ) ; >>DiskDriveGetFileAllocationTable ------------------ SABDU001.DLL API: DiskDriveGetFileAllocationTable - UINT FAR PASCAL DiskDriveGetFileAllocationTable ( VOID far * pCDiskDrive, LPBYTE lpbyFATBuffer, UINT nFAT ) pCDiskDrive Pointer to DiskDrive object. lpbyFATBuffer Pointer to buffer for FAT. nFAT Number of FAT to read. Reads a File Allocation Table. Returns: non-zero if successfull, zero if not successfull Example: VOID far *pCDiskDriveA ; LPBYTE lpbyFATBuffer ; FARPROC lpfnNewHandleStatus ; lpbyFATBuffer = new BYTE[_FAT_SIZE] ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; DiskDriveGetFileAllocationTable ( pCDiskDriveA, lpbyFATBuffer, 1 ) ; >>DiskDrivePutFileAllocationTable ------------------ SABDU001.DLL API: DiskDrivePutFileAllocationTable - UINT FAR PASCAL DiskDrivePutFileAllocationTable ( VOID far * pCDiskDrive, LPBYTE lpbyFATBuffer, UINT nFAT ) pCDiskDrive Pointer to DiskDrive object. lpbyFATBuffer Pointer to buffer for FAT. nFAT Number of FAT to write. Writes a File Allocation Table. Returns: non-zero if successfull, zero if not successfull Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; DiskDrivePutFileAllocationTable ( pCDiskDriveA, lpbyFATBuffer, 1 ) ; >>DiskDriveGetAllocatedSectors ------------------ SABDU001.DLL API: DiskDriveGetAllocatedSectors ---- UINT FAR PASCAL DiskDriveGetAllocatedSectors ( pCDiskDrive ) pCDiskDrive Pointer to DiskDrive object. Returns: number of allocated sectors Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; nAllocatedSectors = DiskDriveGetAllocatedSectors ( pCDiskDriveA ) ; >>DiskDriveGetRootDirectory ------------------ SABDU001.DLL API: DiskDriveGetRootDirectory ------- UINT FAR PASCAL DiskDriveGetRootDirectory ( VOID far * pCDiskDrive, LPBYTE lpbyBuffer ) pCDiskDrive Pointer to DiskDrive object. lpbyBuffer Pointer to buffer to read root directory into. Reads Root Directory. Returns: non-zero if successfull, zero if not successfull Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; LPBYTE lpbyDirectoryBuffer ; lpbyDirectoryBuffer = new BYTE[_SIZE_OF_ROOT_DIRECTORY] lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; DiskDriveGetRootDirectory ( pCDiskDriveA, lpbyDirectoryBuffer ) ; >>DiskDrivePutRootDirectory ------------------ SABDU001.DLL API: DiskDrivePutRootDirectory ------- UINT FAR PASCAL DiskDrivePutRootDirectory ( VOID far * pCDiskDrive, LPBYTE lpbyBuffer ) pCDiskDrive Pointer to DiskDrive object. lpbyBuffer Pointer to buffer to write root directory from. Writes Root Directory. Returns: non-zero if successfull, zero if not successfull Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; DiskDrivePutRootDirectory ( pCDiskDriveA, lpbyDirectoryBuffer ) ; >>DiskDriveReadSectors ------------------ SABDU001.DLL API: DiskDriveReadSectors ------------ UINT FAR PASCAL DiskDriveReadSectors ( VOID far * pCDiskDrive, UINT nCylinder, UINT nHead, UINT nSector, UINT nCount, LPBYTE lpbyBuffer, lpfnHANDLESTATUS lpfnHandleStatus ) pCDiskDrive Pointer to DiskDrive object. nCylinder Starting Cylinder number. nHead Starting Head number. nSector Starting Sector number. nCount Number of sectors to read. lpbyBuffer Pointer to buffer to read into. lpfnNewHandleStatus Pointer to routine to handle status callbacks Reads a group of sectors. Returns: zero if successfull, status code if not successfull. Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; DiskDriveReadSectors ( pCDiskDriveA, 0, 1, 0, 18, lpbyBuffer, lpfnNewHandleStatus ) ; >>DiskDriveWriteSectors ------------------ SABDU001.DLL API: DiskDriveWriteSectors ----------- UINT FAR PASCAL DiskDriveWriteSectors ( VOID far * pCDiskDrive, UINT nCylinder, UINT nHead, UINT nSector, UINT nCount, LPBYTE lpbyBuffer, lpfnHANDLESTATUS lpfnHandleStatus ) pCDiskDrive Pointer to DiskDrive object. nCylinder Starting Cylinder number. nHead Starting Head number. nSector Starting Sector number. nCount Number of sectors to write. lpbyBuffer Pointer to buffer to write from. lpfnNewHandleStatus Pointer to routine to handle status callbacks Writes a group of sectors. Returns: zero if successfull, status code if not successfull. Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', FD1440, 0, lpfnNewHandleStatus ) ; DiskDriveWriteSectors ( pCDiskDriveA, 0, 1, 0, 18, lpbyBuffer, lpfnNewHandleStatus ) ; >>DiskDriveLetter ------------------ SABDU001.DLL API: DiskDriveWriteLetter ------------ UINT FAR PASCAL DiskDriveLetter ( VOID far * pCDiskDrive, ) pCDiskDrive Pointer to DiskDrive object. Returns: Letter of virtual drive. Example: VOID far *pCDiskDriveA ; char cDriveLetter ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', FD1440, 0, lpfnNewHandleStatus ) ; ... cDriveLetter = DiskDriveLetter ( pCDiskDriveA ) ; >>DiskDriveSetRead ------------------ SABDU001.DLL API: DiskDriveSetRead --------------- UINT FAR PASCAL DiskDriveSetRead ( VOID far *pCDiskDrive, UINT nTempType, UINT nCylinders ) pCDiskDrive Pointer to DiskDrive object. nTempType Defines type of diskette FD0360 FD0720 FD1200 FD1200H FD1440 FD1440H FD2880 nCylinders Number of cylinders NULL indicates default to type Sets contained virtual drive for reading. Returns: zero if successfull, status code if not successfull. Example: VOID far *pCDiskDriveA ; char cDriveLetter ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', FD1440, 0, lpfnNewHandleStatus ) ; ... DiskDriveSetRead ( pCDiskDriveA, nTempType, nCylinders ) ; >>DiskDriveSetWrite ------------------ SABDU001.DLL API: DiskDriveSetWrite--------------- UINT FAR PASCAL DiskDriveSetWrite ( VOID far * pCDiskDrive, UINT nTempType, UINT nCylinders ) pCDiskDrive Pointer to DiskDrive object. nTempType Defines type of diskette FD0360 FD0720 FD1200 FD1200H FD1440 FD1440H FD2880 nCylinders Number of cylinders NULL indicates default to type Sets contained virtual drive for writing. Returns: zero if successfull, status code if not successfull. Example: VOID far *pCDiskDriveA ; char cDriveLetter ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', FD1440, 0, lpfnNewHandleStatus ) ; ... DiskDriveSetWrite ( pCDiskDriveA, nTempType, nCylinders ) ; >>DiskDriveSetWriteFormatOption ------------------ SABDU001.DLL API: DiskDriveSetWriteFormatOption -- VOID FAR PASCAL DiskDriveSetWriteFormatOption ( VOID far * pCDiskDrive, UINT nWriteFormatOptionNew ) pCDiskDrive Pointer to DiskDrive object. nWriteFormatOptionNew New value for Write Format Option 1 AUTOMATIC 2 ALWAYS 3 NEVER 4 FAST Sets write format option. Returns: VOID Example: VOID far *pCDiskDriveA ; char cDriveLetter ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', FD1440, 0, lpfnNewHandleStatus ) ; ... DiskDriveSetWriteFormatOption ( pCDiskDriveA, AUTOMATIC ) ; >>DiskDriveSetWriteVerifyOption ------------------ SABDU001.DLL API: DiskDriveSetWriteVerifyOption -- VOID FAR PASCAL DiskDriveSetWriteVerifyOption ( VOID far * pCDiskDrive, BOOL bWriteVerifyOptionNew ) pCDiskDrive Pointer to DiskDrive object. bWriteVerifyOptionNew New value of Write Verify Option. 0 Verify off 1 Verify on Sets write verify option. Returns: VOID Example: VOID far *pCDiskDriveA ; char cDriveLetter ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', FD1440, 0, lpfnNewHandleStatus ) ; ... DiskDriveSetWriteVerifyOption ( pCDiskDriveA, TRUE ) ; >>DiskDriveReset ------------------ SABDU001.DLL API: DiskDriveReset ------------------ UINT FAR PASCAL DiskDriveReset ( VOID far * pCDiskDrive ) pCDiskDrive Pointer to DiskDrive object. Resets virtual drive Returns: zero if successfull, status code if not successfull. Example: VOID far *pCDiskDriveA ; char cDriveLetter ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', FD1440, 0, lpfnNewHandleStatus ) ; ... DiskDriveReset ( pCDiskDriveA ) ; >>DiskDriveForceReset ------------------ SABDU001.DLL API: DiskDriveForceReset ------------- UINT FAR PASCAL DiskDriveForceReset ( VOID far * pCDiskDrive ) pCDiskDrive Pointer to DiskDrive object. Forces reset of virtual drive Returns: zero if successfull, status code if not successfull. Example: VOID far *pCDiskDriveA ; char cDriveLetter ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', FD1440, 0, lpfnNewHandleStatus ) ; ... DiskDriveForceReset ( pCDiskDriveA ) ; >>DiskDriveType ------------------ SABDU001.DLL API: DiskDriveType ------------------- UINT FAR PASCAL DiskDriveType ( VOID far * pCDiskDrive ) pCDiskDrive Pointer to DiskDrive object. Returns: Type ( density ). Example: VOID far *pCDiskDriveA ; char cDriveLetter ; FARPROC lpfnNewHandleStatus ; UINT nType ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; ... nType = DiskDriveType ( pCDiskDriveA ) ; >>DiskDriveHasData ------------------ SABDU001.DLL API: DiskDriveHasData ---------------- UINT FAR PASCAL DiskDriveHasData ( VOID far * pCDiskDrive ) pCDiskDrive Pointer to DiskDrive object. Returns: TRUE if DiskDrive is valid object. Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; ... if ( DiskDriveHasData ( pCDiskDriveA ) ) ...; >>DiskDriveHasError ------------------ SABDU001.DLL API: DiskDriveHasError --------------- UINT FAR PASCAL DiskDriveHasError ( VOID far * pCDiskDrive ) pCDiskDrive Pointer to DiskDrive object. Returns: TRUE if DiskDrive object had an error. Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; ... if ( DiskDriveHasError ( pCDiskDriveA ) ) ...; >>DiskDriveIsTruncated ------------------ SABDU001.DLL API: DiskDriveIsTruncated ------------ UINT FAR PASCAL DiskDriveIsTruncated ( VOID far * pCDiskDrive ) pCDiskDrive Pointer to DiskDrive object. Returns: TRUE if DiskDrive is truncated. Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; ... if ( DiskDriveIsTruncated ( pCDiskDriveA ) ) ...; >>DiskDriveFormat ------------------ SABDU001.DLL API: DiskDriveFormat ----------------- UINT FAR PASCAL DiskDriveFormat ( VOID far * pCDiskDrive, LPCSTR lpczVolumeLabel, UNIT nFormatOption, LPBYTE lpbyBootSector, lpfnHANDLESTATUS lpfnHandleStatus ) pCDiskDrive Pointer to DiskDrive object. lpczVolumeLabel Pointer to new volume label. nFormatOption Format option. 0x0010 FORMATFAST 0x0020 FORMATQUICK lpbyBootSector Pointer to new boot sector code. lpfnNewHandleStatus Pointer to routine to handle status callbacks Formats DiskDrive object. Returns: FALSE if successfull. Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; UINT nType ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; ... DiskDriveFormat ( pCDiskDriveA, "VOL 1", FORMATFAST, NULL, NULL ) ; >>DiskDriveSetType ------------------ SABDU001.DLL API: DiskDriveSetType ---------------- VOID FAR PASCAL DiskDriveSetType ( VOID far * pCDiskDrive, UINT nNewType ) pCDiskDrive Pointer to DiskDrive object. nNewType Defines type of diskette FD0360 FD0720 FD1200 FD1200H FD1440 FD1440H FD2880 Sets diskette type. Returns: VOID Example: VOID far *pCDiskDriveA ; char cDriveLetter ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; ... DiskDriveSetType ( pCDiskDriveA, FD1200 ) ; >>DiskDriveUsedCylinders ------------------ SABDU001.DLL API: DiskDriveUsedCylinders ---------- UINT FAR PASCAL DiskDriveUsedCylinders ( VOID far * pCDiskDrive ) pCDiskDrive Pointer to DiskDrive object. Returns: Number of cylinders. Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; UINT nCylinder ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; ... nCylinder = DiskDriveUsedCylinders ( pCDiskDriveA ) ; >>DiskDriveUsedHeads ------------------ SABDU001.DLL API: DiskDriveHeads ------------------ UINT FAR PASCAL DiskDriveUsedHeads ( VOID far * pCDiskDrive ) pCDiskDrive Pointer to DiskDrive object. Returns: Number of heads. Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; UINT nHeads ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; ... nHeads = DiskDriveUsedHeads ( pCDiskDriveA ) ; >>DiskDriveUsedSectors ------------------ SABDU001.DLL API: DiskDriveUsedSectors ------------ UINT FAR PASCAL DiskDriveUsedSectors ( VOID far * pCDiskDrive ) pCDiskDrive Pointer to DiskDrive object. Returns: Number of sectors in a track. Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; ... nSectors = DiskDriveUsedSectors ( pCDiskDriveA ) ; >>DiskDriveUsedSectorSize ------------------ SABDU001.DLL API: DiskDriveUsedSectorSize---------- UINT FAR PASCAL DiskDriveUsedSectorSize ( VOID far * pCDiskDrive ) pCDiskDrive Pointer to DiskDrive object. Returns: Sector size. Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; ... nSectorSize = DiskDriveUsedSectorSize ( pCDiskDriveA ) ; >>DiskDriveNumberOfFATs ------------------ SABDU001.DLL API: DiskDriveNumberOfFATs ----------- UINT FAR PASCAL DiskDriveNumberOfFATs ( VOID far * pCDiskDrive ) pCDiskDrive Pointer to DiskDrive object. Returns: Number of File Allocation Tables Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; UINT nNumberOfFATs ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; ... nNumberOfFATs = DiskDriveNumberOfFATs ( pCDiskDriveA ) ; >>DiskDriveSectorsPerCluster ------------------ SABDU001.DLL API: DiskDriveSectorsPerCluster ------ UINT FAR PASCAL DiskDriveSectorsPerCluster ( VOID far * pCDiskDrive ) pCDiskDrive Pointer to DiskDrive object. Returns: Number sectors in a cluster. Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; UINT nSectorsPerCluster ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; ... nSectorsPerCluster = DiskDriveSectorsPerCluster ( pCDiskDriveA ) ; >>DiskDriveSectorsPerFAT ------------------ SABDU001.DLL API: DiskDriveSectorsPerFAT ---------- UINT FAR PASCAL DiskDriveSectorsPerFAT ( VOID far * pCDiskDrive ) pCDiskDrive Pointer to DiskDrive object. Returns: Number sectors in a file allocation table. Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; UINT nSectorsPerFAT ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; ... nSectorsPerFAT = DiskDriveSectorsPerFAT ( pCDiskDriveA ) ; >>DiskDriveRootDirectoryEntries ------------------ SABDU001.DLL API: DiskDriveRootDirectoryEntries --- UINT FAR PASCAL DiskDriveRootDirectoryEntries ( VOID far * pCDiskDrive ) pCDiskDrive Pointer to DiskDrive object. Returns: Number of entries in root directory. Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; UINT nRootDirectoryEntries ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; ... nRootDirectoryEntries = DiskDriveRootDirectoryEntries ( pCDiskCDriveA ) ; >>DiskDriveGetVolumeDate ------------------ SABDU001.DLL API: DiskDriveGetVolumeDate -------- UINT FAR PASCAL DiskDriveGetVolumeDate ( VOID far * pCDiskDrive, LPSTR lpczOldVolumeDate ) pCDiskDrive Pointer to DiskDrive object. lpczOldVolumeDate Pointer to date buffer. Returns: lpczOldVolumeDate. Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; LPBYTE lpczOldVolumeDate ; lpczOldVolumeDate = new BYTE[_SIZE_OF_DATE] lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; ... DiskDriveGetVolumeDate ( pCDiskDriveA, lpczOldVolumeDate ) ; >>DiskDriveGetVolumeLabel ------------------ SABDU001.DLL API: DiskDriveGetVolumeLabel -------- UINT FAR PASCAL DiskDriveGetVolumeLabel ( VOID far * pCDiskDrive, LPSTR lpczOldVolumeLabel ) pCDiskDrive Pointer to DiskDrive object. lpczOldVolumeLabel Pointer to volume label buffer. Copies volume label into lpczOldVolumeLabel. Returns: lpczOldVolumeLabel. Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; LPBYTE lpczOldVolumeLabel ; lpczVolumeLabel = new BYTE[_SIZE_OF_VOLUME_LABEL] lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; ... DiskDriveGetVolumeLabel ( pCDiskDriveA, lpczOldVolumeLabel ) ; >>DiskDriveSetVolumeLabel ------------------ SABDU001.DLL API: DiskDriveSetVolumeLabel -------- UINT FAR PASCAL DiskDriveSetVolumeLabel ( VOID far * pCDiskDrive, LPSTR lpczNewVolumeLabel ) pCDiskDrive Pointer to DiskDrive object. lpczNewVolumeLabel Pointer to new volume label. Sets volume label to lpczNewVolumeLabel. Returns: FALSE if successfull. Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; ... DiskDriveSetVolumeLabel ( pCDiskDriveA, "Vol 1" ) ; >>DiskDriveTruncate ------------------ SABDU001.DLL API: DiskDriveTruncate --------------- VOID FAR PASCAL DiskDriveTruncate ( VOID far * pCDiskDrive ) pCDiskDrive Points to DiskDrive object. Turns on truncation. Returns: VOID Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; ... DiskDriveTypeTruncate ( pCDiskDriveA ) ; >>DiskDriveTruncateRevers ------------------ SABDU001.DLL API: DiskDriveTruncateReverse -------- UINT FAR PASCAL DiskDriveTruncateReverse ( VOID far * pCDiskDrive ) pCDiskDrive Points to DiskDrive object. Turns off truncation. Returns: VOID Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; ... DiskDriveTruncateReverse ( pCDiskDriveA ) ; >>DiskDriveWriteBootSector ------------------ SABDU001.DLL API: DiskDriveWriteBootSector -------- UINT FAR PASCAL DiskDriveWriteBootSector ( VOID far * pCDiskDrive, lpbyModelBootSector, lpfnHANDLESTATUS lpfnNewHandleStatus ) pCDiskDrive Pointer to DiskDrive object. lpbyModelBootSector Pointer to new boot sector model (code). NULL indicates use standard boot sector code. lpfnNewHandleStatus Pointer to routine to handle status callbacks Writes boot sector. Returns: False if successfull. Example: VOID far *pCDiskDriveA ; FARPROC lpfnNewHandleStatus ; lpfnNewHandleStatus = MakeProcInstance ( hInstance, NewHandleStatus ) ; pCDiskDriveA = DiskDriveCreateDrive ( 'A', 0, 0, lpfnNewHandleStatus ) ; ... DiskDriveTypeWriteBootSector ( pCDiskDriveA, NULL, NULL ) ; >>FDrive ------------------ SABDU001.DLL API: FDrive objects ------------------ A FDrive (File Drive) is a specialized version of the VDrive (Virtual Drive). It is an object that represents a diskette image file. The following functions are available to manipulate it: FDriveCreate Creates a FDrive object FDriveDelete Deletes a FDrive object FDriveForceReset Issues a reset to the drive FDriveFormatTrack Formats a track FDriveReadSectors Reads a group of sectors from the drive FDriveReset Issues a reset to the drive if it was used FDriveSetRead Sets up for reading from the drive FDriveSetWrite Sets up for writing to the drive FDriveWriteSectors Writes a group of sectors to the drive >>FDriveCreate ------------------ SABDU001.DLL API: FDriveCreate -------------------- VOID far * FAR PASCAL FDriveCreate ( LPCSTR lpczFileName, LPCSTR lpczApplicationTitle, LPCSTR lpczVersion, lpfnHANDLESTATUS lpfnNewHandleStatus ) lpczFileName Pointer to file name to be used. lpczApplicationTitle Pointer to application title. lpczVersion Pointer to version. lpfnNewHandleStatus Points to a callback routine that handles event notifications including errors. Creates a FDrive object associated with file name. Returns: Pointer to FDrive object. Example: VOID far *pDriveA ; pDrive = FDriveCreate ( "MyFileName", "SAB Diskette Utility", "2.10", lpfnHandleStatus ) ; >>FDriveDelete ------------------ SABDU001.DLL API: FDriveDelete -------------------- VOID FAR PASCAL FDriveDelete ( pFDrive ) pFDrive Points to FDrive object to be deleted. Deletes the FDrive object pointed to by pFDrive. Returns: VOID Example: VOID far *pDriveA ; pDrive = FDriveCreate ( "MyFileName", "SAB Diskette Utility", "2.10" ) ; ... FDriveDelete ( pDrive ) ; pDrive = NULL ; >>FDriveSetRead ------------------ SABDU001.DLL API: FDriveSetRead ------------------- UINT FAR PASCAL FDriveSetRead ( VOID far *pFDrive, UINT nTempType, UINT nCylinders ) pFDrive Points to the FDrive object. nTempType Defines the type of diskette expected: FD0360 FD0720 FD1200 FD1440 FD2880 nCylinders Defines the number of cylinders. NULL indicates default for type. Prepares the FDrive object pointed to by pFDrive for reading. Returns: zero if successfull, status code if not successfull. Example: VOID far *pDriveA ; pDrive = FDriveCreate ( "MyFileName", "SAB Diskette Utility", "2.10" ) ; ... FDriveSetRead ( pDrive, FD0360, NULL ) ; >>FDriveSetWrite ------------------ SABDU001.DLL API: FDriveSetWrite ------------------ UINT FAR PASCAL FDriveSetWrite ( VOID far *pFDrive, UINT nTempType, UINT nCylinders ) pFDrive Points to the FDrive object. nTempType Defines the type of diskette expected: FD0360 FD0720 FD1200 FD1440 FD2880 nCylinders Defines the number of cylinders. NULL indicates default for type. Prepares the FDrive object pointed to by pFDrive for writing. Returns: zero if successfull, status code if not successfull. Example: VOID far *pDriveA ; pDrive = FDriveCreate ( "MyFileName", "SAB Diskette Utility", "2.10" ) ; ... FDriveSetWrite ( pDrive, FD0360, NULL ) ; >>FDriveReset ------------------ SABDU001.DLL API: FDriveReset --------------------- UINT FAR PASCAL FDriveReset ( VOID far *pFDrive ) pFDrive Points to the FDrive object. Resets the FDrive object pointed to by pFDrive. Returns: zero if successfull, status code if not successfull. Example: VOID far *pDriveA ; pDrive = FDriveCreate ( "MyFileName", "SAB Diskette Utility", "2.10" ) ; ... FDriveReset ( pDrive ) ; >>FDriveForceReset ------------------ SABDU001.DLL API: FDriveForceReset ---------------- UINT FAR PASCAL FDriveForceReset ( VOID far *pFDrive ) pFDrive Points to FDrive object. Resets the FDrive object pointed to by pFDrive. Returns: zero if successfull, status code if not successfull. Example: VOID far *pDriveA ; pDrive = FDriveCreate ( "MyFileName", "SAB Diskette Utility", "2.10" ) ; ... FDriveForceReset ( pDrive ) ; >>FDriveFormatTrack ------------------ SABDU001.DLL API: FDriveFormatTrack --------------- UINT FAR PASCAL FDriveForceReset ( VOID far *pFDrive, UNIT nCylinder, UNIT nHead ) pFDrive Points to FDrive Object nCylinder Number of Cylinder to be formatted nHead Number of Head to be formatted Formats a track. Returns: zero if successfull, status code if not successfull Example: VOID far *pDriveA ; pDrive = FDriveCreate ( "MyFileName", "SAB Diskette Utility", "2.10" ) ; ... FDriveFormatTrack ( pDrive, nCylinder, nHead ) ; >>FDriveReadSectors ------------------ SABDU001.DLL API: FDriveReadSectors --------------- UINT FAR PASCAL FDriveReadSectors ( VOID far *pFDrive, UNIT nCylinder, UNIT nHead, UINT nSector, UINT nCount, LPBYTE lpcBuffer ) pFDRive Points to FDrive object. nCylinder Cylinder to read from nHead Head to read with nSector Starting sector nCount Number of sectors to read lpcBuffer Buffer to contain the data read. Reads a group of sectors. Returns: zero if successfull, status code if not successfull. Example: VOID far *pDriveA ; pDrive = FDriveCreate ( "MyFileName", "SAB Diskette Utility", "2.10" ) ; ... FDriveReadSectors ( pDrive, nCylinder, nHead, nSector, nCount, lpcBuffer ) ; >>FDriveWriteSectors ------------------ SABDU001.DLL API: FDriveWriteSectors -------------- UINT FAR PASCAL FDriveWriteSectors ( VOID far *pFDrive, UNIT nCylinder, UNIT nHead, UINT nSector, UINT nCount, LPBYTE lpcBuffer ) pFDrive Points to FDrive object. nCylinder Cylinder to write to nHead Head to write with nSector Starting sector nCount Number of sectors to write lpcBuffer Buffer that contains the data to be written. Writes a group of sectors from the drive pointerd to by pFDrive Returns: zero if successfull, status code if not successfull. Example: VOID far *pDriveA ; pDrive = FDriveCreate ( "MyFileName", "SAB Diskette Utility", "2.10" ) ; ... FDriveWriteSectors ( pDrive, nCylinder, nHead, nSector, nCount, lpcBuffer ) ; >>HandleStatus ------------------ SABDU001.DLL Callback: HandleStatus --------------- typedef int (FAR PASCAL __export * lpfnHANDLESTATUS)( UINT nStatus1, UINT nStatus2, UINT nParam1, UINT nParam2, LONG lParam1, LONG lParam2 ) ; int FAR PASCAL __export HandleStatus ( UINT nStatus1, UINT nStatus2, UINT nParam1, UINT nParam2, LONG lParam1, LONG lParam2 ) ; nStatus1 ------------------- nStatus2 nParam1 nParam2 --------------------------- --------------------- -------------------- lParam1 lParam2 --------------------- --------------- STATUS1_INIT hWnd hInstance STATUS1_START STATUS1_BOOT_SECTOR STATUS1_DIRECTORY STATUS1_FAT STATUS1_SYSTEM_FILE STATUS1_CYLINDER cylinder percent complete STATUS1_CLUSTER cluster percent complete STATUS1_HEAD cylinder percent complete head STATUS1_END STATUS1_ERROR STATUS2_FILE STATUS3_OPEN_FAIL file name pointer STATUS2_FILE STATUS3_OPEN_FILE_IO_ERROR file name pointer STATUS2_FILE STATUS3_OPEN_INPUT_BAD file name pointer STATUS2_FILE STATUS3_OPEN_FLAGS_BAD file name pointer STATUS2_FILE STATUS3_OPEN_NOT_SUPPORTED file name pointer STATUS2_READ cylinder head STATUS2_WRITE cylinder head STATUS2_FORMAT cylinder head STATUS2_FILE_READ file name pointer STATUS2_FILE_WRITE file name pointer STATUS2_DISK_SPACE space needed space available STATUS2_HEAD cylinder head STATUS2_MEMORY STATUS2_SYSTEM STATUS2_FAT STATUS2_DIRECTORY STATUS2_SYSTEM_BOOT_SECTOR STATUS2_BOOT_SECTOR STATUS2_SYSTEM_FILE_MISSING STATUS2_SYSTEM_FILE_OPEN STATUS2_COMPARE cylinder head STATUS2_DPT STATUS2_SECTORS target sectors source sectors target cylinders source cylinders STATUS2_CLUSTER >>MDrive ------------------ SABDU001.DLL API: MDrive objects ------------------ A MDrive (Memory Drive) is a specialized version of the VDrive (Virtual Drive). It is an object that represents a diskette image in memory. The following functions are available to manipulate it: MDriveCreate Creates a MDrive object MDriveDelete Deletes a MDrive object MDriveForceReset Issues a reset to the drive MDriveFormatTrack Formats a track MDriveReadSectors Reads a group of sectors from the drive MDriveReset Issues a reset to the drive if it was used MDriveSetRead Sets up for reading from the drive MDriveSetWrite Sets up for writing to the drive MDriveWriteSectors Writes a group of sectors to the drive >>MDriveCreate ------------------ SABDU001.DLL API: MDriveCreate -------------------- VOID far * FAR PASCAL MDriveCreate ( UINT nMemory, lpfnHANDLESTATUS lpfnNewHandleStatus ) nMemory Identifier for MDrive object. lpfnNewHandleStatus Points to a callback routine that handles event notifications including errors. Creates a MDrive object associated with drive cDrive. Returns: Pointer to MDrive object. Example: VOID far *pDrive1 ; pDrive1 = MDriveCreate ( 1, lpfnHandleStatus ) ; >>MDriveDelete ------------------ SABDU001.DLL API: MDriveDelete -------------------- VOID FAR PASCAL MDriveDelete ( pMDrive ) pMDrive Points to MDrive object to be deleted. Deletes the MDrive object pointed to by pMDrive. Returns: VOID Example: VOID far *pDrive1 ; pDrive1 = MDriveCreate ( 1 ) ; ... MDriveDelete ( pDrive1 ) ; pDrive1 = NULL ; >>MDriveSetRead ------------------ SABDU001.DLL API: MDriveSetRead ------------------- UINT FAR PASCAL MDriveSetRead ( VOID far *pMDrive, UINT nTempType, UINT nCylinders ) pMDrive Points to the MDrive object. nTempType Defines the type of diskette expected: FD0360 FD0720 FD1200 FD1440 FD2880 nCylinders Defines the number of cylinders. NULL indicates default for type. Prepares the MDrive object pointed to by pMDrive for reading. Returns: zero if successfull, status code if not successfull. Example: VOID far *pDrive1 ; pDrive1 = MDriveCreate ( 1 ) ; ... MDriveSetRead ( pDrive1, FD0360, NULL ) ; >>MDriveSetWrite ------------------ SABDU001.DLL API: MDriveSetWrite ------------------ UINT FAR PASCAL MDriveSetWrite ( VOID far *pMDrive, UINT nTempType, UINT nCylinders ) pMDrive Points to the MDrive object. nTempType Defines the type of diskette expected: FD0360 FD0720 FD1200 FD1440 FD2880 nCylinders Defines the number of cylinders. NULL indicates default for type. Prepares the MDrive object pointed to by pMDrive for writing. Returns: zero if successfull, status code if not successfull. Example: VOID far *pDrive1 ; pDrive1 = MDriveCreate ( 1 ) ; ... MDriveSetWrite ( pDrive1, FD0360, NULL ) ; >>MDriveReset ------------------ SABDU001.DLL API: MDriveReset --------------------- UINT FAR PASCAL MDriveReset ( VOID far *pMDrive ) pMDrive Points to the MDrive object. Resets the MDrive object pointed to by pMDrive. Returns: zero if successfull, status code if not successfull Example: VOID far *pDrive1 ; pDrive1 = MDriveCreate ( 1 ) ; ... MDriveReset ( pDrive1 ) ; >>MDriveForceReset ------------------ SABDU001.DLL API: MDriveForceReset ---------------- UINT FAR PASCAL MDriveForceReset ( VOID far *pMDrive ) pMDrive Points to MDrive object. Resets the MDrive object pointed to by pMDrive. Returns: zero if successfull, status code if not successfull. Example: VOID far *pDrive1 ; pDrive1 = MDriveCreate ( 1 ) ; ... MDriveForceReset ( pDrive1 ) ; >>MDriveFormatTrack ------------------ SABDU001.DLL API: MDriveFormatTrack --------------- UINT FAR PASCAL MDriveForceReset ( VOID far *pMDrive, UNIT nCylinder, UNIT nHead ) pMDrive Points to MDrive Object nCylinder Number of Cylinder to be formatted nHead Number of Head to be formatted Formats a track. Returns: zero if successfull, status code if not successfull Example: VOID far *pDrive1 ; pDrive1 = MDriveCreate ( 1 ) ; ... MDriveFormatTrack ( pDrive1, nCylinder, nHead ) ; >>MDriveReadSectors ------------------ SABDU001.DLL API: MDriveReadSectors --------------- UINT FAR PASCAL MDriveReadSectors ( VOID far *pMDrive, UNIT nCylinder, UNIT nHead, UINT nSector, UINT nCount, LPBYTE lpcBuffer ) pDDRive Points to MDrive object. nCylinder Cylinder to read from nHead Head to read with nSector Starting sector nCount Number of sectors to read lpcBuffer Buffer to contain the data read. Reads a group of sectors. Returns: zero if successfull, status code if not successfull. Example: VOID far *pDrive1 ; pDrive1 = MDriveCreate ( 1 ) ; ... MDriveReadSectors ( pDrive1, nCylinder, nHead, nSector, nCount, lpcBuffer ) ; >>MDriveWriteSectors ------------------ SABDU001.DLL API: MDriveWriteSectors -------------- UINT FAR PASCAL MDriveWriteSectors ( VOID far *pMDrive, UNIT nCylinder, UNIT nHead, UINT nSector, UINT nCount, LPBYTE lpcBuffer ) pMDrive Points to MDrive object. nCylinder Cylinder to write to nHead Head to write with nSector Starting sector nCount Number of sectors to write lpcBuffer Buffer that contains the data to be written. Writes a group of sectors from the drive pointerd to by pMDrive Returns: zero if successfull, status code if not successfull. Example: VOID far *pDrive1 ; pDrive1 = MDriveCreate ( 1 ) ; ... MDriveWriteSectors ( pDrive1, nCylinder, nHead, nSector, nCount, lpcBuffer ) ; >>VDrive ------------------ SABDU001.DLL API: VDrive objects ------------------ A VDrive (Virtual Drive) is an object that represents a diskette image. The following functions are available to manipulate it: VDriveFlag Returns the flags for the virtual drive VDriveForceReset Forces a reset of the virtual drive VDriveFormatTrack Formats a track VDriveIsRemote Returns TRUE if media is remote VDriveIsRemovable Returns TRUE if media is removable VDriveIsUseable Returns TRUE if media is useable VDriveIsUsed Returns TRUE if virtual drive was used VDriveLetter Returns letter of vitual drive VDriveNumberOfCylinders Returns number of cylinders VDriveNumberOfHeads Returns number of heads VDriveNumberOfSectors Returns number of sectors VDriveReadSectors Reads a group of sectors from the vitual drive VDriveReset Resets the virtual drive if it was used VDriveSetRead Sets up the virtual drive for reading VDriveSetType Sets the type (density) of the virtual drive VDriveSetWrite Sets up the virtual drive for writing VDriveType Returns the type (density) of the virtual drive VDriveWriteSectors Writes a group of sectors to the virutal drive >>VDriveSetType ------------------ SABDU001.DLL API: VDriveSetType ------------------- UINT FAR PASCAL VDriveSetType ( VOID far *pCVDrive, UINT nType ) pCVDrive Pointer to VDrive object. nNewType Defines type of diskette FD0360 FD0720 FD1200 FD1200H FD1440 FD1440H FD1680 FD2880 Sets diskette type. Returns: nType if successfull or FD0000 if not. Example: VOID far *pDriveA ; VDriveSetType ( pDriveA, FD0720 ) ; >>VDriveLetter ------------------ SABDU001.DLL API: VDriveLetter -------------------- char FAR PASCAL VDriveLetter ( VOID far *pCVDrive ) pCVDrive Pointer to VDrive object. Returns: Drive identifier. Example: VOID far *pDriveA ; char cDrive ; cDrive = VDriveLetter ( pDriveA ) ; >>VDriveType ------------------ SABDU001.DLL API: VDriveType ---------------------- UINT FAR PASCAL VDriveType ( VOID far *pCVDrive ) pCVDrive Pointer to VDrive object. Returns: Drive type (density). Example: VOID far *pDriveA ; UINT nType ; nType = VDriveType ( pDriveA ) ; >>VDriveFlag ------------------ SABDU001.DLL API: VDriveFlag ---------------------- UINT FAR PASCAL VDriveFlag ( VOID far *pCVDrive ) pCVDrive Pointer to VDrive object. Returns: Drive flag. Example: VOID far *pDriveA ; UINT nFlag ; nFlag = VDriveFlag ( pDriveA ) ; >>VDriveNumberOfCylinders ------------------ SABDU001.DLL API: VDriveNumberOfCylinders --------- UINT FAR PASCAL VDriveNumberOfCylinders ( VOID far *pCVDrive ) pCVDrive Pointer to VDrive object. Returns: Number of cylinders. Example: VOID far *pDriveA ; UINT nCylinders ; nCylinders = VDriveNumberOfCylinders ( pDriveA ) ; >>VDriveNumberOfHeads ------------------ SABDU001.DLL API: VDriveNumberOfHeads ------------- UINT FAR PASCAL VDriveNumberOfHeads ( VOID far *pCVDrive ) pCVDrive Pointer to VDrive object. Returns: Number of heads. Example: VOID far *pDriveA ; UINT nHeads ; nHeads = VDriveNumberOfHeads ( pDriveA ) ; >>VDriveNumberOfSectors ------------------ SABDU001.DLL API: VDriveNumberOfSectors ----------- UINT FAR PASCAL VDriveNumberOfSectors ( VOID far *pCVDrive ) pCVDrive Pointer to VDrive object. Returns: Number of sectors. Example: VOID far *pDriveA ; UINT nSectors ; nSectors = VDriveNumberOfSectors ( pDriveA ) ; >>VDriveIsRemote ------------------ SABDU001.DLL API: VDriveIsRemote ------------------ BOOL FAR PASCAL VDriveIsRemote ( VOID far *pCVDrive ) pCVDrive Pointer to VDrive object. Returns: TRUE if the media is remote. Example: VOID far *pDriveA ; BOOL bRemote ; bRemote = VDriveIsRemote ( pDriveA ) ; >>VDriveIsDoubleSpaceCVF ------------------ SABDU001.DLL API: VDriveIsDoubleSpaceCVF ---------- BOOL FAR PASCAL VDriveIsDoubleSpaceCVF ( VOID far *pCVDrive ) pCVDrive Pointer to VDrive object. Returns: TRUE if the media is is a Double Spaced CVF. Example: VOID far *pDriveA ; BOOL bDoubleSpaceCVF ; bDoubleSpaceCVF = VDriveIsDoubleSpaceCVF ( pDriveA ) ; >>VDriveIsDoubleSpaceHost ------------------ SABDU001.DLL API: VDriveIsDoubleSpaceHost --------- BOOL FAR PASCAL VDriveIsDoubleSpaceHost ( VOID far *pCVDrive ) pCVDrive Pointer to VDrive object. Returns: TRUE if the media is a Double Space host drive. Example: VOID far *pDriveA ; BOOL bDoubleSpaceHost ; bDoubleSpaceHost = VDriveIsDoubleSpaceHost ( pDriveA ) ; >>VDriveIsDriveSpaceCVF ------------------ SABDU001.DLL API: VDriveIsDriveSpaceCVF ---------- BOOL FAR PASCAL VDriveIsDriveSpaceCVF ( VOID far *pCVDrive ) pCVDrive Pointer to VDrive object. Returns: TRUE if the media is is a Drive Spaced CVF. Example: VOID far *pDriveA ; BOOL bDriveSpaceCVF ; bDriveSpaceCVF = VDriveIsDriveSpaceCVF ( pDriveA ) ; >>VDriveIsDriveSpaceHost ------------------ SABDU001.DLL API: VDriveIsDriveSpaceHost --------- BOOL FAR PASCAL VDriveIsDriveSpaceHost ( VOID far *pCVDrive ) pCVDrive Pointer to VDrive object. Returns: TRUE if the media is a Drive Space host drive. Example: VOID far *pDriveA ; BOOL bDriveSpaceHost ; bDriveSpaceHost = VDriveIsDriveSpaceHost ( pDriveA ) ; >>VDriveIsRemovable ------------------ SABDU001.DLL API: VDriveIsRemovable --------------- BOOL FAR PASCAL VDriveIsRemovable ( VOID far *pCVDrive ) pCVDrive Pointer to VDrive object. Returns: TRUE if the media is removable. Example: VOID far *pDriveA ; BOOL bRemovable ; bRemovable = VDriveIsRemovable ( pDriveA ) ; >>VDriveIsUseable ------------------ SABDU001.DLL API: VDriveIsUseable ----------------- BOOL FAR PASCAL VDriveIsUseable ( VOID far *pCVDrive ) pCVDrive Pointer to VDrive object. Returns: TRUE if the media is useable. Example: VOID far *pDriveA ; BOOL bUseable ; bUseable = VDriveIsUseable ( pDriveA ) ; >>VDriveIsUsed ------------------ SABDU001.DLL API: VDriveIsUsed -------------------- BOOL FAR PASCAL VDriveIsUsead ( VOID far *pCVDrive ) pCVDrive Pointer to VDrive object. Returns: TRUE if the media is used. Example: VOID far *pDriveA ; BOOL bUsed ; bUsed = VDriveIsUsed ( pDriveA ) ; >>VDriveReset ------------------ SABDU001.DLL API: VDriveReset --------------------- UINT FAR PASCAL VDriveReset ( VOID far *pCVDrive ) pCVDrive Pointer to VDrive object. Resets virtual drive. Returns FALSE if successfull. Example: VOID far *pDriveA ; BOOL bReset ; bReset = !VDriveReset ( pDriveA ) ; >>VDriveFormatTrack ------------------ SABDU001.DLL API: VDriveFormatTrack --------------- UINT FAR PASCAL VDriveFormatTrack ( VOID far *pCVDrive, UINT nCylinder, UINT nHead ) pCVDrive Pointer to VDrive object. nCylinder Number of Cylinder. nHead Number of Head. Formats track. Returns: FALSE if successfull. Example: VOID far *pDriveA ; BOOL bFormat ; bFormat = !VDriveFormatTrack ( pDriveA, nCylinder, nHead ) ; >>VDriveReadSectors ------------------ SABDU001.DLL API: VDriveReadSectors --------------- UINT FAR PASCAL VDriveReadSectors ( VOID far *pCVDrive, UINT nCylinder, UINT nHead, UINT nSector, UINT nCount, LPBYTE lpcBuffer ) pCVDrive Pointer to VDrive object. nCylinder Number of Cylinder. nHead Number of Head. nSector Number of Starting Sector. nCount Number of sectors to be read. lpcBuffer Pointer to buffer to be read into. Reads sectors. Returns: FALSE if successfull. Example: VOID far *pDriveA ; BOOL bRead ; bRead = !VDriveReadSectors ( pDriveA, nCylinder, nHead, nSector, nCount, LPBYTE lpcBuffer ) ; >>VDriveWriteSectors ------------------ SABDU001.DLL API: VDriveWriteSectors -------------- UINT FAR PASCAL VDriveWriteSectors ( VOID far *pCVDrive, UINT nCylinder, UINT nHead, UINT nSector, UINT nCount, LPBYTE lpcBuffer ) pCVDrive Pointer to VDrive object. nCylinder Number of Cylinder. nHead Number of Head. nSector Number of Starting Sector. nCount Number of sectors to be written. lpcBuffer Pointer to buffer to be written from. Writes sectors. Returns: FALSE if successfull. Example: VOID far *pDriveA ; BOOL bWrite ; bWrite = !VDriveWriteSectors ( pDriveA, nCylinder, nHead, nSector, nCount, LPBYTE lpcBuffer ) ;