submitting a form with a link

Results 1 to 2 of 2

Thread: submitting a form with a link

  1. #1
    Join Date
    Dec 1969

    Default submitting a form with a link

    Can somebody please help me with this it is late in the day and I am totally struggling? Here's what I need. I need a hidden text field on a page(form1.aspx) and a link that submits the value of the hidden text field to another form(form2.aspx) when clicked. How would I go about doing this and capturing the value on the form(form2.aspx) that I submitted to. I am thinking of using JavaScript to submit the form when the link is clicked and my .net language is c#. Also why can I not set the action to my first form when I add runat=server it autmaticall sets action to form1.aspx.

  2. #2
    Join Date
    Dec 1969

    Default because of the postback

    .net is architectured so that a page acts like a single form. you wouldn't normally use 2 forms talking to each other (usually). you'd pass variables either through a constructor or through an init call. you could get creative with it and set a server cookie and get it on form2... or maybe a session variable. or you could just use Server.Transfer. i'd look it up on if i were you.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts