OS2.org Site Index - Feedback - Impressum
Sprachauswahl / Choose your Language News Software Hardware Projekte Forum Tipps Links Verschiedenes
Editorial Diskussion HelpDesk Umfrage
[Forum]
in nach (Erweiterte Suche)
[Forum]
( Archiv ) ( Neues Thema )
15.01.2001
ODIN: verschiedene Arbeitsweise für GetDriveType (von: GA, 15:59:34) ^
Unter Win 95 und Win NT arbeiten GetDriveType verschieden:

There are three problems with the
GetDeviceType API: (1) if you have a path which contains a file name, it returns the error code
DRIVE_NO_ROOT_DIR; (2) it works differently on Windows NT and Windows 95; (3) if you pass it a string
that contains a name like "\.d" it does not recognize the local drive. This code fixes these problems. It strips
back the name until it has either a drive letter (C:, for example), or a network path name (\ prefix). It discards any
file name portion. It also handles paths that do not contain a drive or UNC name. The program knows how to
compensate for the fact that Windows 95 and Windows NT _splitpath parse differently.

GetDriveType("C:") returns DRIVE_FIXED on NT 4.0 and DRIVE_NO_ROOT_DIR on Win95.

GetDriveType("C:") returns DRIVE_FIXED on both systems.

Den ganzen Artikel einschließlich eines Testbeispiels kann man hier einsehen:

http://codeguru.earthweb.com/system/getdrivetypeexplorer.shtml
[ Leser: 90 ]

Datum Thema
06.01.2017 *

*

Name: * eMail: Benachrichtigung

Mit * markierte Felder müssen ausgefüllt werden !

( Zeige alle Einträge ) ( Zur Startübersicht )
Thema von: Leser Datum Zeit
 ODIN: verschiedene Arbeitsweise für GetDriveType
GA9015.01.200115:59


php.net OpenIT © 1998-2017 by WebTeam OS2.org