Results 1 to 7 of 7
  1. #1
    5 Star Lounger
    Join Date
    Jan 2002
    Location
    Midlothian, Virginia, USA
    Posts
    874
    Thanks
    0
    Thanked 2 Times in 1 Post

    What Causes 'Device not Available' Error

    A user of my database called to say that after recovering from some system problems he cannot open the database. He gets a "Device not Available" error message after logging into the database. Any idea what kind of things cause that error message?

    Thanks,
    Bill

  2. #2
    Uranium Lounger
    Join Date
    Jan 2001
    Location
    Cincinnati, Ohio, USA
    Posts
    7,089
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: What Causes 'Device not Available' Error

    Bill, can you provide some additional information? What type of database is it, SQL, Access, Oracle, something else entirely? Is the database local to the computer and on its hard drive or on a network?

    What kind of "system problems" were recovered from? That may also be significant.

    You may want to check the ODBC settings if they are utilized.
    -Mark

  3. #3
    5 Star Lounger
    Join Date
    Jan 2002
    Location
    Midlothian, Virginia, USA
    Posts
    874
    Thanks
    0
    Thanked 2 Times in 1 Post

    Re: What Causes 'Device not Available' Error

    Mark, thanks for replying so quickly. (I started to reply to you just a few minutes after you posted your message, but my PC hung after I finished writing my message and before I posted it! Then I got a whole series of interruptions!) This problem is in Texas and I am in Virginia and the guy out there has limited computer experience so I'm almost as much in the dark as you are! It is an Access 97 database, split between front-end and back-end, with security activated. It is running on a peer-to-peer network, in Win98, in a Habitat for Humanity office. I don't have any idea what went wrong out there but apparently someone 'fixed it' and the database wouldn't open so my contact went in to get it running again. I've tried every kind of disconnect and path error I can think of in the database setup and I can't make a message like that come up. I talked to my contact out there a short time ago. By opening the database with the shift key depressed the database opens OK and the back-end is linked OK with the front-end. However, when some of my code runs to check to see if the table links are OK, the problem occurs! That code tries to access the registry. I had him comment-out that code and the problem doesn't occur!

    Do you know if trying to read a non-existent registry key would cause the "Device not available" error. I certainly thought I was using fail-safe code in that area anyway but I haven't had time to go review all of it yet. The thing that really puzzles me is that the error message dialog box has "Habitat Database" in the title bar but isn't a message that my code displays, because all my messages say a lot more than that, plus I've searched my code for that text. I wouldn't have expected the database's name to be in the message title if the OS put up the message! The primary purpose in my post here was to see if there is some known connection between that error message and certain kinds of problems.

    Thanks,
    Bill

  4. #4
    Super Moderator
    Join Date
    Aug 2001
    Location
    Evergreen, CO, USA
    Posts
    6,623
    Thanks
    3
    Thanked 60 Times in 60 Posts

    Re: What Causes 'Device not Available' Error

    Hi Bill -
    This is just a hunch, but the fact that you have security active means Access looks for information in the registry relative to the workgroup path. Is it possible that somebody did a registry restore and dropped a bunch of entries that should be there? I'm also curious what your code is doing with the registry - I've seen a couple of applications that do that, but it's pretty unusual if all you need to do is check your table links. You might also want to look at your error handling code - it may be the it is somehow being subverted and giving you a bogus error message. Hope this helps, and please post the resolution when you find it - the answer could be of great value to others.
    Wendell

  5. #5
    Plutonium Lounger
    Join Date
    Dec 2000
    Location
    Sacramento, California, USA
    Posts
    16,775
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: What Causes 'Device not Available' Error

    Are you using the registry to store the share path for the linked database? Is it possible that the shares got remapped? Trying to share an Access database on a peer-to-peer network is a <img src=/S/hairout.gif border=0 alt=hairout width=31 height=23> exercise, especially if some bright soul insists on using the "server" machine as a workstation as well, since his drive maps will be different. Access hates that!
    Charlotte

  6. #6
    5 Star Lounger
    Join Date
    Jan 2002
    Location
    Midlothian, Virginia, USA
    Posts
    874
    Thanks
    0
    Thanked 2 Times in 1 Post

    Re: What Causes 'Device not Available' Error

    Charlotte, I believe you've hit the nail on the head! We have never used mapped drive letters here and I wasn't aware of them being used in the Texas installation but I just tried to duplicate the situation where the back-end is connected through a mapped drive and then the drive mapping is changed and that caused that same error. So, I imagine that is their problem.

    Thanks so much for your post!
    Bill

  7. #7
    5 Star Lounger
    Join Date
    Jan 2002
    Location
    Midlothian, Virginia, USA
    Posts
    874
    Thanks
    0
    Thanked 2 Times in 1 Post

    Re: What Causes 'Device not Available' Error

    Wendell, thanks for the hunch. I supply the path to the workgroup file in the startup shortcut and it appears to get past that before the error comes up so I don't think that could be the issue. I use the registry to store the latest path to the back-end database. If the startup code finds that a particular table is not linked properly it retrieves the back-end path from the registry and checks to see if it points to a file with the right name. If it does not, then it opens a dialog box for the user to go find the back-end file. In that case, the resulting path is first installed in that registry item for future use. Of course, that registry string is not there when the database is stored in a new PC and that situation is handled OK. I also store a temporary flag in the registry. I have a special form for debugging that sets that flag and then runs the startup code again and that code actually checks for that flag before checking for the properly linked table and if it is set it resets it and opens the dialog box for the user to find the back-end. This provides an easy way to manually link to a different back-end. The error occurs after the point when the startup code checks that flag but no problem occurs at the point where the flag is being set by the debug form! If I could make it happen I could step through the code and see where it actually is generating the error message, but I can't make it happen. I may have to resort to trying to step my contact in Texas through that code!

    I was hoping someone would know what kinds of problems can cause that error message. <img src=/S/evilgrin.gif border=0 alt=evilgrin width=15 height=15>

    Thanks,
    Bill

    Added Later: See my reply to Charlotte. I suspect she has pin pointed the problem!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •