I got the following error debugging an ASP.NET project earlier today:
                Auto-attach to process '[2440] w3wp.exe' on machine '...' failed. Error code 
                    0x8013134b.
                The problem was that I had installed .NET 2.0 which had registered ASP.NET 2.0 on
                the Web Site I was trying to debug. The site I was trying to debug was in .Net1.1.
                Fixing it is simple:
                * Run the IIS Manager(Write inetmgr in run window)
                * Right click on the web site with the problem
                * Click the ASP.NET tab
                * Change the ASP.NET version from 2.something to 1.something in the combo and debugging
                works again