Need asp form to redirect after submit in Expression c#

Have managed to create an aspx page in Expression web using a few tutorials, with validators etc and everything is working OK but I need to know how to get the page to redirect to a thank you/confirmation page once the submit button is pressed. Have used some instruction from jimcobooks to create the form in C# but I have no knowledge of this programming language so struggling as you could imagine. I would also like to make the email take data form some of the text boxes in the form and use this as the subject of the email. Any help greatly appreciated.
pn944Asked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

jinn_hnnlCommented:
You have the register.aspx page or whatever, inside that page you have several controls TextBox, dropdown ...

In asp.net 2.0 the principle of each page submit is the page postback to itself. And 1 aspx page should only have 1 form.

When the page is posted back, you can access server control (which have property runat="server") and its property.

<asp:TextBox ID="tbName" runat="server" />
<asp:Button ID="btSubmit" runat="server" OnClick="btSubmit_Click" />

codebehind:
protected void btSubmit_Click(object sender, EventArgs e)
{
        string name = tbName.Text;
        ...
       //get all  your data and send email
      SaveUserData();
      SendConfirmEmail();
      Response.Redirect("successpage.aspx"); //this is to redirect to the success page
}

Hope this give you some idea

JINN
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
jinn_hnnlCommented:
If you want example to send email using C#, take a look at this, it's ready to run example. Copy and try it out

http://www.experts-exchange.com/Programming/Languages/.NET/Q_23840055.html

JINN
0
pn944Author Commented:
Thanks for the quick response, sorted now, thanks again
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
ASP

From novice to tech pro — start learning today.