Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / ASP.NET / General / October 2007

Tip: Looking for answers? Try searching our database.

System.io. in VS.NET 2005 debug

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
mr t - 29 Oct 2007 07:34 GMT
I have a website set up this way...

http://localhost <- project root.
http://localhost/Files <- vir dir (not application. just vir dir) with
write permissions.

1. Start VS.NET 2005 debugging. (must be vs.net 2005, not 2003)
2. Using code, System.IO.Directory.CreateDirectory a sub dir inside /
Files, something like, /Files/Images
3. Stop debugging.
4. Start debugging again, and do System.IO.Directory.Delete on the dir
you created. /Files/Images. No exception is thrown.

RESULT on my WIN XP Pro, IIS 5, .NET FWK 2.0:

The directory does not delete. it becomes inaccessible.

5. Now, stop debugging. still the dir is there but inaccessible.
6. Now, close VS.NET 2005. Now the directory is deleted as if it was
following the code step 4, delayed.

is this a known bug?
Michael Nemtsev, MVP - 29 Oct 2007 08:43 GMT
Hello mr t,

probably you started File bases project, not IIS one
In this case the ASP.net development server is started, which hosts your
app- you can see the icon into the notification area.
This app host your site, and doesn't unload when you stop debuggin. That's
why your site folder is not accessable to be deleted.
if your close the ASP.net development server from the notification area manually
- everything will be ok

---
WBR,
Michael  Nemtsev [.NET/C# MVP] :: blog: http://spaces.live.com/laflour 

"The greatest danger for most of us is not that our aim is too high and we
miss it, but that it is too low and we reach it" (c) Michelangelo

m> I have a website set up this way...
m>
m> http://localhost <- project root.
m> http://localhost/Files <- vir dir (not application. just vir dir)
m> with
m> write permissions.
m> 1. Start VS.NET 2005 debugging. (must be vs.net 2005, not 2003)
m> 2. Using code, System.IO.Directory.CreateDirectory a sub dir inside /
m> Files, something like, /Files/Images
m> 3. Stop debugging.
m> 4. Start debugging again, and do System.IO.Directory.Delete on the
m> dir
m> you created. /Files/Images. No exception is thrown.
m> RESULT on my WIN XP Pro, IIS 5, .NET FWK 2.0:
m>
m> The directory does not delete. it becomes inaccessible.
m>
m> 5. Now, stop debugging. still the dir is there but inaccessible.
m> 6. Now, close VS.NET 2005. Now the directory is deleted as if it was
m> following the code step 4, delayed.
m> is this a known bug?
m>
mr t - 29 Oct 2007 17:45 GMT
You know, I was opening as a "Web Site", instead of a "Project/
Solution". when I changed to solution, it seems to be working, at
least for now.

strange that it would not execute code commands when you run it the
other way.

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.