views:

27

answers:

1

I realize this is somewhat similar to other questions here, but I've been through everything I can find, and still haven't gotten anywhere. It's very humbling.

I have a small asp.net web site that we use internally for some simple logs, like a timesheet and a support log. These use Access databases on a network share (using domain users). I'm moving the web site from a virtual machine that runs Windows 2000 to one that runs Windows XP, and I'm not able to access the databases. I get an error like:

ERROR [HY024] [Microsoft][ODBC Microsoft Access Driver] '(unknown)' is not a valid path. Make sure that the path name is spelled correctly and that you are connected to the server on which the file resides.

The configuration is (or should be) the same on both sites:

  • I'm using the data sources applet to create system DSNs, so my connection strings are along the lines of "DSN=timesheet"
  • I use impersonation so that the asp.net process uses a domain account. My web.config file has an identity tag with a domain user and password (yes, this isn't what you'd call best practices in security).

This all works fine on the Windows 2000 site, but not on the XP version. I created a small page to check the network access. Basically:

SysAcctLabel.Text = System.Security.Principal.WindowsIdentity.GetCurrent().Name;

//  Get list of available drives
Response.Write("Available drive letters:<br/>");
string[] drives = Directory.GetLogicalDrives();
foreach (string drive in drives)
{
    Response.Write(drive + "<br/>");
}

In the aspx file, I also show the value of Environment.UserName.

On both sites, the user information shows the same values, but on the Windows 2000 version I see the network drives in the list, and on the XP version I don't.

Any ideas out there?

Thanks

Tom

A: 

Have you tried logging onto the server interactively as that user and see what drive letters are mapped? Maybe you need to map the drive letters as that user first (and check the 'connect next time' checkbox).

Jonathan
Yup, I log in as the domain user and look in Windows explorer and all the drives are there
jackjumper