I have been working on an ASP.Net web site and have been publishing to my server with no issues. I decided to change the path that it was being published to a few steps down so that everything would be more logically placed.
Before : C:/inetpub/wwwroot/(HERE)
After I got everything how I wanted it i changed it to down 2 steps.
After : C:/inetpub/wwwroot/super/duper/(HERE)
It wasn’t until I cleaned up the top level stuff that was just in /wwwroot/ that everything started to break. I would get errors saying that my .ashx handler couldn’t be found. After staring blankly for a few hours, I moved my /super/duper/bin/ file to the top level, /inetpub/wwwroot/bin/, and viola. It worked.
Now my question is, why did this have this effect, when the entire time the /bin/ file was web accessable?
I think what the other answers and this question is alluding to is that it is not enough just to move the folder to the location that you wish to reference your site from and more importantly run your code from. The way I see it is you have two options.
Option 1.
Leave the bin folder at the WWWROOT level but move the other items into the folder structure you want. The runtime will load the dll in the bin folder into the app pool and your aspx’s etc. should see it.
Option 2.
Create a virtual folder / application at the level you want and drop everything in there.
Option 2 is better I think.
Also if you are not using ~ in your urls you might want to take a look at that.