Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. Error: It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level

Error: It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level

Scheduled Pinned Locked Moved ASP.NET
helpcsharpasp-netwindows-admintutorial
12 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • U Offline
    U Offline
    User 2456424
    wrote on last edited by
    #1

    When Rebuild web.net asp.net error "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." press F5 to run normally, but Rebuild the error above, this error how to fix it? error

    Richard DeemingR F 2 Replies Last reply
    0
    • U User 2456424

      When Rebuild web.net asp.net error "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." press F5 to run normally, but Rebuild the error above, this error how to fix it? error

      Richard DeemingR Offline
      Richard DeemingR Offline
      Richard Deeming
      wrote on last edited by
      #2

      As the error message says: This error can be caused by a virtual directory not being configured as an application in IIS. asp.net - Error to use a section registered as allowDefinition='MachineToApplication' beyond application level - Stack Overflow[^]


      "These people looked deep within my soul and assigned me a number based on the order in which I joined." - Homer

      "These people looked deep within my soul and assigned me a number based on the order in which I joined" - Homer

      U 1 Reply Last reply
      0
      • Richard DeemingR Richard Deeming

        As the error message says: This error can be caused by a virtual directory not being configured as an application in IIS. asp.net - Error to use a section registered as allowDefinition='MachineToApplication' beyond application level - Stack Overflow[^]


        "These people looked deep within my soul and assigned me a number based on the order in which I joined." - Homer

        U Offline
        U Offline
        User 2456424
        wrote on last edited by
        #3

        I have read this article but it does not apply to my program

        Richard DeemingR 1 Reply Last reply
        0
        • U User 2456424

          I have read this article but it does not apply to my program

          Richard DeemingR Offline
          Richard DeemingR Offline
          Richard Deeming
          wrote on last edited by
          #4

          Well, given the huge amount of information you've provided, I'm sure somebody will be able to come up with a solution for you. :doh: </SARCASM> Remember, we can't see your screen, access your computer, or read your mind. All we have to go on is the information you put in this little box. So far, the only information you've provided is that you get this error, and that the actual cause of this error "doesn't apply" to your application.


          "These people looked deep within my soul and assigned me a number based on the order in which I joined." - Homer

          "These people looked deep within my soul and assigned me a number based on the order in which I joined" - Homer

          1 Reply Last reply
          0
          • U User 2456424

            When Rebuild web.net asp.net error "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." press F5 to run normally, but Rebuild the error above, this error how to fix it? error

            F Offline
            F Offline
            F ES Sitecore
            wrote on last edited by
            #5

            You probably have your main web.config in a sub-folder of your site. Either by accident or because your site is misconfigured in IIS (if the site root folder is "mysite" you can't dump a website at "mysite/subsite"). As we can't access your system from here and you have provided no real information beyond the error, it's hard to give specific advice.

            U 1 Reply Last reply
            0
            • F F ES Sitecore

              You probably have your main web.config in a sub-folder of your site. Either by accident or because your site is misconfigured in IIS (if the site root folder is "mysite" you can't dump a website at "mysite/subsite"). As we can't access your system from here and you have provided no real information beyond the error, it's hard to give specific advice.

              U Offline
              U Offline
              User 2456424
              wrote on last edited by
              #6

              I just started learning asp.net webform myself, I don't understand webform much, I don't know what information you need? In your opinion, if I have a Web.config file I don't need to declare the above error, if I have two "mysite/subsite" Web.config files, how do I register them? I sent the Web.config file and reported an error to you: [Web](http://www.mediafire.com/file/q583bdw8nx4lxqx/Web.config/file) Error 1 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. C:\WebSite2010\App_Data\Web.config 22 I will send the image of the program, you see the attached image http://www.mediafire.com/view/dpkqjr7yunbhjc4/website2010\_01.jpg/file I have used IIS, you see the attached image http://www.mediafire.com/view/rzf3pcy4wtjg2su/website2010\_02.jpg/file If you need any information what, please ask me.

              F 1 Reply Last reply
              0
              • U User 2456424

                I just started learning asp.net webform myself, I don't understand webform much, I don't know what information you need? In your opinion, if I have a Web.config file I don't need to declare the above error, if I have two "mysite/subsite" Web.config files, how do I register them? I sent the Web.config file and reported an error to you: [Web](http://www.mediafire.com/file/q583bdw8nx4lxqx/Web.config/file) Error 1 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. C:\WebSite2010\App_Data\Web.config 22 I will send the image of the program, you see the attached image http://www.mediafire.com/view/dpkqjr7yunbhjc4/website2010\_01.jpg/file I have used IIS, you see the attached image http://www.mediafire.com/view/rzf3pcy4wtjg2su/website2010\_02.jpg/file If you need any information what, please ask me.

                F Offline
                F Offline
                F ES Sitecore
                wrote on last edited by
                #7

                An IIS site can only host one website, so one folder with web.config in the root. If you want to host multiple sites then you need an new IIS site created for each one, and they can't be in sub-folders of each other; /site1/web.config /site2/web.config You would register a site in folder "site1" and one in "site2". If you have this arrangement /mysite/site1/web.config /mysite/site2/web.config and register an IIS site at "mysite" thinking you can then do http://mysite/site1 and http://mysite/site2 then you'll get the error you have now. If you do want one site nested inside another you need to create what is called a virtual directory. Google for how to create sites in IIS, this is all well documented.

                U 1 Reply Last reply
                0
                • F F ES Sitecore

                  An IIS site can only host one website, so one folder with web.config in the root. If you want to host multiple sites then you need an new IIS site created for each one, and they can't be in sub-folders of each other; /site1/web.config /site2/web.config You would register a site in folder "site1" and one in "site2". If you have this arrangement /mysite/site1/web.config /mysite/site2/web.config and register an IIS site at "mysite" thinking you can then do http://mysite/site1 and http://mysite/site2 then you'll get the error you have now. If you do want one site nested inside another you need to create what is called a virtual directory. Google for how to create sites in IIS, this is all well documented.

                  U Offline
                  U Offline
                  User 2456424
                  wrote on last edited by
                  #8

                  I understand what you mean, I deleted all the web.config, I left only one web.config file at the root directory, then the error occurred: The type 'XXX' in 'c:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\YYY' conflicts with the imported type 'XXX' in 'c:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\ZZZ'. Using the type defined in 'c:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\YYY'. c:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\YYY how to fix this error ?

                  F 1 Reply Last reply
                  0
                  • U User 2456424

                    I understand what you mean, I deleted all the web.config, I left only one web.config file at the root directory, then the error occurred: The type 'XXX' in 'c:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\YYY' conflicts with the imported type 'XXX' in 'c:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\ZZZ'. Using the type defined in 'c:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\YYY'. c:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\YYY how to fix this error ?

                    F Offline
                    F Offline
                    F ES Sitecore
                    wrote on last edited by
                    #9

                    Delete the temporary .net files and just make sure the site is deployed correctly, make sure you have project references where one project access another's code, make sure you're not defining the same type in two projects, and so on. The fact that you deleted all web.configs leaving one makes me think you still don't have a properly deployed solution. If you did there wouldn't be multiple configs. Google how to deploy a VS project to IIS to make sure you're doing it properly.

                    U 1 Reply Last reply
                    0
                    • F F ES Sitecore

                      Delete the temporary .net files and just make sure the site is deployed correctly, make sure you have project references where one project access another's code, make sure you're not defining the same type in two projects, and so on. The fact that you deleted all web.configs leaving one makes me think you still don't have a properly deployed solution. If you did there wouldn't be multiple configs. Google how to deploy a VS project to IIS to make sure you're doing it properly.

                      U Offline
                      U Offline
                      User 2456424
                      wrote on last edited by
                      #10

                      I find a lot of information on google on this error but I have not found any article to fix this error. I went to the directories: C:\Users\Administrator\AppData\Local\Temp\WebSitePublish\xxx C:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\xxx C:\Windows\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\xxx to delete but when I Rebuild reappears with another name whose extension has not been changed, how do I fix it ? I submitted a sample of my faulty program, what errors can you see ? You see my attached file: [WebSite2010](http://www.mediafire.com/file/k4q5t9dxo6ov833/WebSite2010.rar/file) I searched the Internet for errors that were similar to my program errors, viewing and reference. This error may also show up [c# - Namespace class conflict - Stack Overflow](https://stackoverflow.com/questions/8724606/namespace-class-conflict) 1. Close Visual Studio 2. Clear Temporary ASP.NET Files directories by clearing the following folders: C:\Windows\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\ C:\Windows\Microsoft.NET\Framework64\v2.0.50727\Temporary ASP.NET Files\ C:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\ C:\Windows\Microsoft.NET\Framework64\v4.0.30319\Temporary ASP.NET Files\ C:\Users\[your_user_name]\AppData\Local\Temp\Temporary ASP.NET Files\ Restart the World Wide Web Publishing service (Start menu\Settings\Control Panel\Administrative tools\Services). 3. Clear the project's Bin and Obj folders and deploy new assemblies if it is necessary; 4. Rebuild your application

                      F 1 Reply Last reply
                      0
                      • U User 2456424

                        I find a lot of information on google on this error but I have not found any article to fix this error. I went to the directories: C:\Users\Administrator\AppData\Local\Temp\WebSitePublish\xxx C:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\xxx C:\Windows\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\xxx to delete but when I Rebuild reappears with another name whose extension has not been changed, how do I fix it ? I submitted a sample of my faulty program, what errors can you see ? You see my attached file: [WebSite2010](http://www.mediafire.com/file/k4q5t9dxo6ov833/WebSite2010.rar/file) I searched the Internet for errors that were similar to my program errors, viewing and reference. This error may also show up [c# - Namespace class conflict - Stack Overflow](https://stackoverflow.com/questions/8724606/namespace-class-conflict) 1. Close Visual Studio 2. Clear Temporary ASP.NET Files directories by clearing the following folders: C:\Windows\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\ C:\Windows\Microsoft.NET\Framework64\v2.0.50727\Temporary ASP.NET Files\ C:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\ C:\Windows\Microsoft.NET\Framework64\v4.0.30319\Temporary ASP.NET Files\ C:\Users\[your_user_name]\AppData\Local\Temp\Temporary ASP.NET Files\ Restart the World Wide Web Publishing service (Start menu\Settings\Control Panel\Administrative tools\Services). 3. Clear the project's Bin and Obj folders and deploy new assemblies if it is necessary; 4. Rebuild your application

                        F Offline
                        F Offline
                        F ES Sitecore
                        wrote on last edited by
                        #11

                        The error is probably a red herring, the issue is that you simply haven't deployed correctly. We can't access your machine, we don't know how your project is set up, or your IIS or your folders or anything.

                        U 1 Reply Last reply
                        0
                        • F F ES Sitecore

                          The error is probably a red herring, the issue is that you simply haven't deployed correctly. We can't access your machine, we don't know how your project is set up, or your IIS or your folders or anything.

                          U Offline
                          U Offline
                          User 2456424
                          wrote on last edited by
                          #12

                          Did you see the example I sent you ? According to you, how to fix the above error ?

                          1 Reply Last reply
                          0
                          Reply
                          • Reply as topic
                          Log in to reply
                          • Oldest to Newest
                          • Newest to Oldest
                          • Most Votes


                          • Login

                          • Don't have an account? Register

                          • Login or register to search.
                          • First post
                            Last post
                          0
                          • Categories
                          • Recent
                          • Tags
                          • Popular
                          • World
                          • Users
                          • Groups