summaryrefslogtreecommitdiff
path: root/win32
diff options
context:
space:
mode:
authorIan C <ianc@noddybox.co.uk>2005-10-16 12:49:39 +0000
committerIan C <ianc@noddybox.co.uk>2005-10-16 12:49:39 +0000
commit6060eef8fe323e721903533ab39b80f4cb9fd22e (patch)
tree4f1c7f75ec55cb924a58cd8d820d6fe8f3ffc9ec /win32
parent8e9898787bd63c35e204d7f88e704ce34426c58f (diff)
Added win32 module
Diffstat (limited to 'win32')
-rw-r--r--win32/.cvsignore2
-rw-r--r--win32/test.bmx38
2 files changed, 40 insertions, 0 deletions
diff --git a/win32/.cvsignore b/win32/.cvsignore
new file mode 100644
index 0000000..8f686ea
--- /dev/null
+++ b/win32/.cvsignore
@@ -0,0 +1,2 @@
+test.debug.exe
+.bmx \ No newline at end of file
diff --git a/win32/test.bmx b/win32/test.bmx
new file mode 100644
index 0000000..5429281
--- /dev/null
+++ b/win32/test.bmx
@@ -0,0 +1,38 @@
+' $Id$
+
+Import noddybox.win32
+Strict
+
+Local drives:Int=W32GetLogicalDrives()
+
+For Local b:Int=0 To 27
+ Local m:Int=1 Shl b
+
+ If (drives &m)=m
+ Local root:String=Chr(65+b)+":"
+ Local t:String
+
+ Select W32GetDriveType(root)
+ Case DRIVETYPE_UNKNOWN
+ t="Unknown"
+ Case DRIVETYPE_NO_ROOT_DIR
+ t="No root dir"
+ Case DRIVETYPE_REMOVABLE
+ t="Removable"
+ Case DRIVETYPE_FIXED
+ t="Fixed"
+ Case DRIVETYPE_REMOTE
+ t="Remote"
+ Case DRIVETYPE_CDROM
+ t="CDROM"
+ Case DRIVETYPE_RAMDISK
+ t="RAM DISK"
+ Default
+ t="*** Bad return ***"
+ End Select
+
+ Print root + " -- " + t
+ EndIf
+Next
+
+Print "Drive mask="+Bin(drives) \ No newline at end of file