Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How do I know size of floppy - 3.5 or 5.25?
Message
 
To
14/04/1999 12:29:24
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Miscellaneous
Thread ID:
00208105
Message ID:
00208541
Views:
21
>>>Hi, All!
>>>
>>>Is there any way to know the 'size' of the floppy drive, whether it's 3.5 or 5.25 inch?
>>>
>>
>>If you can't find any other way, you can use the API call DeviceIOControl() to perform a IOCTL_DISK_GET_DRIVE_GEOMETRY, which returns a DISK_GEOMETRY structure; the MEDIA_TYPE member of the structure tells you the apparent drive geometry.
>>
>>If there's a disk mounted in the drive, SYS(2020) will tell you the actual disk size for the mounted media; this will allow you to identify the disk type mounted (IOW, if you have a 720K disk in the drive, it'll let you know; it's particularly useful on drives like the 'superfloppy' LS-120, which can work with both standard floppy formats and the 120MB superdisks). The SYS(2020) function operates on the default drive; you'll need to SET DEFAULT TO to use it.
>>
>>I'm sure that you could also use one of the Disk Information classes that can be downloaded from here on UT.
>>
>>>Thanks in advance,
>>>
>>>Uri Shohet.
>
>or use a ruler


you beat me to it.
Previous
Reply
Map
View

Click here to load this message in the networking platform