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: Invalid at the top level of the document

Error: Invalid at the top level of the document

Scheduled Pinned Locked Moved ASP.NET
debugginghelplearning
6 Posts 2 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.
  • H Offline
    H Offline
    hi_everybody
    wrote on last edited by
    #1

    Hi, i have published website. At the time of running the site it through an error as follows, Invalid at the top level of the document. Error processing resource 'http://localhost/CompiledSite/SamplePage.aspx'. Line ... This is a marker file generated by the precompilation tool, and should not be deleted! ^ Error: Invalid at the top level of the document why it comes when i run my website at debug mode it runs well but after publishing it, it throughs an error.

    N 1 Reply Last reply
    0
    • H hi_everybody

      Hi, i have published website. At the time of running the site it through an error as follows, Invalid at the top level of the document. Error processing resource 'http://localhost/CompiledSite/SamplePage.aspx'. Line ... This is a marker file generated by the precompilation tool, and should not be deleted! ^ Error: Invalid at the top level of the document why it comes when i run my website at debug mode it runs well but after publishing it, it throughs an error.

      N Offline
      N Offline
      Not Active
      wrote on last edited by
      #2

      Check the web.config file to make sure it hasn't been corrupted.


      I know the language. I've read a book. - _Madmatt

      H 1 Reply Last reply
      0
      • N Not Active

        Check the web.config file to make sure it hasn't been corrupted.


        I know the language. I've read a book. - _Madmatt

        H Offline
        H Offline
        hi_everybody
        wrote on last edited by
        #3

        no yaar the web config is ok my website run well in debugger

        N 1 Reply Last reply
        0
        • H hi_everybody

          no yaar the web config is ok my website run well in debugger

          N Offline
          N Offline
          Not Active
          wrote on last edited by
          #4

          But you said the problem is when you publish it right? That is not the same as debug.


          I know the language. I've read a book. - _Madmatt

          H 1 Reply Last reply
          0
          • N Not Active

            But you said the problem is when you publish it right? That is not the same as debug.


            I know the language. I've read a book. - _Madmatt

            H Offline
            H Offline
            hi_everybody
            wrote on last edited by
            #5

            hmmm but i checked web.config file there no any problem then why this error comes actualy project get published successfully but when i run,it shows this error.

            N 1 Reply Last reply
            0
            • H hi_everybody

              hmmm but i checked web.config file there no any problem then why this error comes actualy project get published successfully but when i run,it shows this error.

              N Offline
              N Offline
              Not Active
              wrote on last edited by
              #6

              Then check SamplePage.aspx, make sure there are no extra characters at the begining. http://www.bing.com/search?q=asp.net+%22Error%3A+Invalid+at+the+top+level+of+the+document%22&form=QBRE&qs=n[^]


              I know the language. I've read a book. - _Madmatt

              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