Wrox Programmer Forums
Go Back   Wrox Programmer Forums > .NET > .NET 2.0 and Visual Studio. 2005 > .NET Framework 2.0
|
.NET Framework 2.0 For discussion of the Microsoft .NET Framework 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the .NET Framework 2.0 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old May 25th, 2006, 07:13 AM
Registered User
 
Join Date: May 2006
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default problem with allowDefinition='MachineToApplication

I have upgraded a .net 1.0 to .net 2.0.

I am getting the following error message:
Build (web): It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level. This error can be caused by a virtual directory not being configured as an application in IIS.

I have been reading around forums and have found any web.config files in the backup version should be removed I have done this and am still getting the error - can anyone help please?


<location path="public">
    <system.web>
      <authentication mode="Forms" />
      <authorization>
        <allow users="julia" />
        <deny users="?" />
      </authorization>

    </system.web>
  </location>



 
Old June 10th, 2006, 01:20 AM
Registered User
 
Join Date: Jun 2006
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

One option:

1. Convert MySite using VS05 wizard
2. Waste an hour Googling on the error message and messing with IIS.
3. Rename MySite folder to MySiteOld (optional)
4. Create a new blank MySite with VS05
5. Gradually copy files across, running site each time
6. Fix various errors that conversion missed (in my case lots of Imports system.data)

My impression: it's an error message that doesn't mean what it says.
Clive


 
Old June 12th, 2006, 10:44 AM
Registered User
 
Join Date: Jun 2006
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

The real reason for the problem is...(probably)

A nice fresh web.config is the main thing as far as I can tell. I put an old copy (1.1) of my web.config in a folder for reference within my 2.0 site and the error reappeared. When I excluded the file, which 2.0 insists you do explicitly, the problem went away.

Hope this helps someone out there.






Similar Threads
Thread Thread Starter Forum Replies Last Post
Error allowdefinition rat ASP.NET 2.0 Basics 11 March 17th, 2009 01:49 AM
CH3 allowDefinition='MachineToApplication' jtavenner BOOK: Beginning ASP.NET 2.0 BOOK VB ISBN: 978-0-7645-8850-1; C# ISBN: 978-0-470-04258-8 2 May 2nd, 2008 07:57 AM
ERROR allowDefinition='MachineToApplication' adamcherochak ASP.NET 2.0 Basics 6 September 7th, 2007 05:43 PM
allowDefinition='MachineToApplication' Error gp2p BOOK: ASP.NET 2.0 Website Programming Problem Design Solution ISBN: 978-0-7645-8464-0 2 May 19th, 2007 08:01 PM
allowDefinition='MachineToApplication' tripathi.vipul ASP.NET 1.0 and 1.1 Basics 0 May 13th, 2006 06:11 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.