473,790 Members | 3,200 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Help with DirectoryNotFou ndException

Two developers here are working on the same code in slightly different
environments. Jason programmed code to access a public folder on an
outside machine "\\usnynyc01ap0 02\". The code works fine on his box. He
is running Win2k3. I am running Windows 2000 Server. Running the same
code I get:

System.IO.Direc toryNotFoundExc eption: Could not find a part of the path
"\\usnynyc01ap0 02\uploadedfile s".

Using the watch window in Visual Studio I discovered that from inside
the code "\\usnynyc01ap0 02" does not exist. I can explore it locally,
but the code can't seem to access it.

I am guessing its a permission issue. The folder on the network is set
to be publicly accessible for everyone. But I still can't seem to find
it. Any suggestions?

Larry Viezel

Feb 15 '06 #1
1 1424
What machine is hosting the folder and what type of set up is it (ie AD
controller, NetBIOS only, etc).

A bit more information may help. You may want to check the ACL list
for the folder, and check inherited permissions. I believe that IUSR_
and INET_ are services or local users or somethin like that so the app
may not be able to access the share.

You might want to try having the application impersonate a user as well
(through web.config or IIS).

Again, more information would be helpful, but maybe my blind guesses
may help.

HTH,
Darren Kopp
http://blog.secudocs.com/

Feb 15 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
53510
by: Matthias Ludwig | last post by:
I'm trying to create a directory on the web server with a vb.net code: .... Dim dirName As String = "w:\filepath\images" If Not Directory.Exists(dirName) Then Directory.CreateDirectory(dirName) Label1.Text = "Directory created" Else
4
4609
by: Frederico Caldeira Knabben | last post by:
Hello, I'm having a problem when trying to use the Directory.CreateDirectory() method. It throws a DirectoryNotFoundException exception. I'll try to illustrate it: Suppose you have the following (existing) directory: d:\Sites\MySite\ And you whant to create the following:
5
2883
by: Andy Lim | last post by:
Hello all, I just moved one of my ASP.NET application to a new hosting. But the same application that used to work perfectly before now returns this error: System.IO.DirectoryNotFoundException What's wrong here? and how to resolve it?
4
2221
by: Jacques Wentworth | last post by:
I'm trying to access a Folder on a different Server using ASP.NET, and are getting a DirectoryNotFoundException. It works fine when I access the local drives on the server. I made sure the folder does exist. I've put my code below to show what I'm trying to do. Thanks Jacques Wentworth
3
1914
by: Joe | last post by:
Hi, I have written a webpage that allows a user to delete files in asp.net with I am having a small problem. To access this page a user has to login via login.aspx page. After successful login, user is directed to a page called view.aspx which shows the user the files in a directory and allows them to delete the files. This page has a data grid having 4 columns - delete button, File Name, Last Write Time and File Size. When a user...
0
267
by: Larry Viezel | last post by:
I posted this problem on another forum previously, any help here would be appreciated: Two developers here are working on the same code in slightly different environments. Jason programmed code to access a public folder on an outside machine "\\usnynyc01ap002\". The code works fine on his box. He is running Win2k3. I am running Windows 2000 Server. Running the same code I get: System.IO.DirectoryNotFoundException: Could not find a...
1
1701
by: Bruce W. Darby | last post by:
My application, prior to building it into an .exe, was working as it should. As soon as I performed the build and attempted to run the application outside the IDE, I got an error message stating DirectoryNotFoundException unhandled. It then gives me the directory that it cannot find and I know why it can't find it... It doesn't exist! What the program is now doing is concatenating the projects directory with the filename of the folder that...
0
1412
by: Dan Christensen | last post by:
Hi, I've been using MSBee to build a small program for some time now (since not everyone seems to have the 2.0 CLI installed yet). Recently I decided to add some buttons that used images, so I naturally placed the images in the project directory, then assembled them into a resource file using the resource editor, which VS2005 placed the final resource file in Properties\Resources.resx. All seemingly normal, no hiccups thus far. ...
0
2057
by: cw808 | last post by:
Hi all. I'm new here but hoping I can get some help for my problem. My situation is that I need to upload files through a C# .NET web application to a file server. I done a search and followed some advice on how to set it up. My environment is Windows 2003 file server, Windows 2000 web service (IIS) and .NET v1.1.4. So far I've done this. Windows 2003 file server: Created an account SHAREUSER. Created a share MEDIA. SHAREUSER is...
1
5413
by: Berryl Hesh | last post by:
I don't know where the "%" sysmbols are coming from, but without them this is a valid directory. I've pasted both the exception and code that triggeered it below. The purpose of this code block is to gather a list of dll's. Thanks - BH Here is the Code /-------------------------------/
0
9512
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10419
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10201
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9987
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9023
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7531
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5424
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
4100
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3709
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.