Hi,

In asp.net I have created a page which contains questions and answers..Answer for each question contains 4 radio buttons ..But i'm not able to calculate the total number of correct n wrong answers..Can anybody tell me how to do it??

Recommended Answers

All 3 Replies

And also i have used the submit button at the end

Each question will have its own radio group so when the submit button is clicked you will need to go through each radio group and find the selected item. This will have to matched against the correct answer, possibly an array holding question number and correct answer. From there keeping a tally of the correct answers is pretty simple. The only real complexity arises if the number of questions on a page isn't set (the same for all time) as then you will need to dynamically determine the number of radio groups on the page.
If you need more input than that post up what you've done and we can have a look.

i got it..tnx..my code is working fine

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.