ASP.NET School Assignment? Project Due Tomorrow? Chat LIVE With A Programming Expert!

Welcome to Dream.In.Code
Become a ASP.NET Expert!

Join 300,475 ASP.NET Programmers for FREE! Get instant access to thousands of ASP.NET experts, tutorials, code snippets, and more! There are 1,737 people online right now. Registration is fast and FREE... Join Now!




How to carry information from one page to another page

 

How to carry information from one page to another page, BEGINNER

ptamzz

4 Jul, 2009 - 11:07 AM
Post #1

D.I.C Head
**

Joined: 4 Mar, 2009
Posts: 62


My Contributions
I'm creating an online exam system. In that, i've to give 10 marks for each correct answer (Radio Button). Now the problem is that, i've assigned a int32 variable the marks; the user must check the 1st question, and then when the button is clicked, the 2nd question will appear, and there the user has to check the radio button and according to the answer chosen, when the button is clicked next, the mark for the 2nd question shall be added to the marks obtained in the first question and so on untill all the questions are over.

So how do i carry the marks information???

User is offlineProfile CardPM
+Quote Post


b.ihde

RE: How To Carry Information From One Page To Another Page

4 Jul, 2009 - 11:56 AM
Post #2

D.I.C for life
Group Icon

Joined: 29 Sep, 2008
Posts: 973



Thanked: 30 times
Dream Kudos: 75
My Contributions
Hi!

Please show us what you have tried so far..

Dream.In.Code has a policy by which we prefer to see a good faith effort on your part before providing source code for homework assignments. Please post the code you have written in an effort to resolve the problem, and our members would be happy to provide some guidance. Be sure to include a description of any errors you are encountering as well.

Please post like this:

Thank you for helping us helping you.

Ben
User is offlineProfile CardPM
+Quote Post

ptamzz

RE: How To Carry Information From One Page To Another Page

4 Jul, 2009 - 12:28 PM
Post #3

D.I.C Head
**

Joined: 4 Mar, 2009
Posts: 62


My Contributions
This is the First page (Default.aspx one) with Question No. 1

CODE

<form id="form1" runat="server" action="Default1.aspx" >
    <div>
    
        Q1: What question no is this question?<br />
        <asp:RadioButton ID="RadioButton1" runat="server" Text="1" />
        <br />
        <asp:RadioButton ID="RadioButton2" runat="server" Text="2" />
        <br />
        <asp:RadioButton ID="RadioButton3" runat="server" Text="3" />
        <br />
        <asp:RadioButton ID="RadioButton4" runat="server" Text="4" />
        <br />
        <asp:Button ID="Button1" runat="server" Text="Button" onclick="Button1_Click" />
    
    </div>
    </form>


when the button is is clicked, the second page will be shown, here "Default1.aspx". In that page, i've the same code but a different question.

In that page, I want to retrieve which radio button the user checked and according to that, assign a variable for the mark. That variable will be added to more marks for each question as the user keeps answering the next and the next question and so on.

Im a complete beginner. Kindly elaborate me if anything is missing.
User is offlineProfile CardPM
+Quote Post

eclipsed4utoo

RE: How To Carry Information From One Page To Another Page

4 Jul, 2009 - 12:52 PM
Post #4

Not Your Ordinary Programmer
Group Icon

Joined: 21 Mar, 2008
Posts: 1,808



Thanked: 201 times
Dream Kudos: 500
Expert In: .NET

My Contributions
to persist data over postbacks and across pages, most people just Session variables.
User is offlineProfile CardPM
+Quote Post

Fast ReplyReply to this topicStart new topic

Time is now: 11/8/09 03:18AM

Live ASP.NET Help!

Be Social

Dream.In.Code RSS Feed Dream.In.Code LinkedIn Group Follow Us On Twitter Fan Us On Facebook

ASP.NET Tutorials

Reference Sheets

ASP.NET Snippets

DIC Chatroom

Bye Bye Ads

Monthly Drawing

Thumb Drive

Top Contributors

Top 10 Kudos This Month