Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Disable/Enable A: and/or other drives 2

Status
Not open for further replies.

NoCoolHandle

Programmer
Apr 10, 2003
2,321
0
0
US
Any idea as to how I could disable and enable a drive with code?

I have a client who experiences wierd caching issues with a floppy drive they have in a system (yeah, yeah)...

If you place a floppy in the drive, from that moment on you will always see that floppy's data. Even if you take the disk out, or replace it with a drive that has different data on it.

What I have found that fix's it, is to disable and enable it via the properties pages.

It would be way easier if I could write a little app to do this for them.. (They aint too compooter savy:)


TIA

Rob
 
From
Q. If I put floppy disc in the A: drive, it works Ok. If I then change the floppy to any other one, it continues to see the first one...

A. The Floppy Disk Drive Phantom Directory Problem

Symptoms: When a floppy disk is inserted into floppy disk drive and the directory is displayed, the directory of the floppy that was previously in the drive is displayed.

Caution: Writing to the second floppy will damage the data on it. The write also writes part or all of the previous floppy's FAT and directory sections.

Background: Pressing the eject button to remove the previous floppy normally sends a Disk Change (DC) signal to the floppy drive controller. If the signal does not get to the controller or the controller is defective, the operating system will not flush the floppy cache'.

Temporary fix: Press Ctrl-C in DOS right after inserting the floppy. That should flush the cache'.

Troubleshooting:

1. Reseat the floppy cable at both ends.

2. Replace the floppy cable. To verify, Check pin 34 continuity.

3. Make sure the pins labeled DC on the floppy drive printed circuit board are jumpered.

4. Dirty (or bad) disk change sensor or LED. Remove floppy, gently open door, and blow dust out of the drive. Carefully clean through floppy door with cotton swab and isopropyl (rubbing) alcohol (use sparingly; keep away from heads).

5. Bad floppy drive printed circuit board. Replace drive.

6. Bad floppy disk controller (part of the motherboard now-a-days). Find a controller card (good luck!), replace the motherboard, or go without.
 
Fully aware of the phantom drive stuff.. the ctrl c doesn't work. The drive doesn't have jumpers.

The only thing that has worked was to either disable and reenable it or to "update the driver"

nothing else fix's the issue.

Tomorrow I try a new tape, next a drive, but It would be much easier to just write the code if I could figure it out.

I suspect it is a win32 call

re 6. Bad floppy disk controller (part of the motherboard now-a-days). Find a controller card (good luck!), replace the motherboard, or go without.


not an option.. these guys don't do cds just floppys.
 
You might be able to find something in WMI. I mean, if there is a property page where you can disable the drive, there has to be a management interface or windows API that can do it.

-Rick

VB.Net Forum forum796 forum855 ASP.NET Forum
[monkey]I believe in killer coding ninja monkeys.[monkey]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top