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
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. Web Development
  3. ASP.NET
  4. Error executing child request for ........

Error executing child request for ........

Scheduled Pinned Locked Moved ASP.NET
helphtmlsysadmindata-structuresdebugging
3 Posts 2 Posters 1 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.
  • I Offline
    I Offline
    Inquire2you
    wrote on last edited by
    #1

    Error executing child request for myhtmpage.htm. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.Web.HttpException: Error executing child request for myhtmpage.htm. Why click xx.aspx is success to display my HTML page, but thisform1.action = "xx.aspx" has above error message ? Is anyone can explain and how solve this problem ? File submit.aspx <%@ Page Language="vb" %> Sub Order() thisform1.action = "xx.aspx" thisform1.submit END SUB

    xx.aspx File xx.aspx <%@ Page Language="vb" %> <% Server.execute("myhtmpage.htm") %> Thank ....

    S 1 Reply Last reply
    0
    • I Inquire2you

      Error executing child request for myhtmpage.htm. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code. Exception Details: System.Web.HttpException: Error executing child request for myhtmpage.htm. Why click xx.aspx is success to display my HTML page, but thisform1.action = "xx.aspx" has above error message ? Is anyone can explain and how solve this problem ? File submit.aspx <%@ Page Language="vb" %> Sub Order() thisform1.action = "xx.aspx" thisform1.submit END SUB

      xx.aspx File xx.aspx <%@ Page Language="vb" %> <% Server.execute("myhtmpage.htm") %> Thank ....

      S Offline
      S Offline
      Stephan Pilz
      wrote on last edited by
      #2

      Hello, In ASPX.Forms you can not change the destination of the submit event. The destination is always the page himself. You can not add a second form in the ASPX-Page too. The next is maybe a solution: 1. add a hidden element in the form: <input type="hidden" id="myAction" name="myAction"> 2. in the sub Order set this element value to xx.aspx: thisForm1.myAction = "xx.aspx" Maybe here is a syntax error, because I do this always in JavaScript;) but the semantic should be clear 3. in Page_Load test the value and do a response redirect if IsPostBack then   if trim(Request.Form("myAction")) <> "" then     Response.Redirect (trim(Request.Form("myAction")))   end if end if Greetings from Stephan

      I 1 Reply Last reply
      0
      • S Stephan Pilz

        Hello, In ASPX.Forms you can not change the destination of the submit event. The destination is always the page himself. You can not add a second form in the ASPX-Page too. The next is maybe a solution: 1. add a hidden element in the form: <input type="hidden" id="myAction" name="myAction"> 2. in the sub Order set this element value to xx.aspx: thisForm1.myAction = "xx.aspx" Maybe here is a syntax error, because I do this always in JavaScript;) but the semantic should be clear 3. in Page_Load test the value and do a response redirect if IsPostBack then   if trim(Request.Form("myAction")) <> "" then     Response.Redirect (trim(Request.Form("myAction")))   end if end if Greetings from Stephan

        I Offline
        I Offline
        Inquire2you
        wrote on last edited by
        #3

        hi Stephan Thank Your Answer. But your method will lost :( all Request.Form value on destination page.

        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