checking a radio button programmatically
-
Am currently working on my end of semester project (online examination system )where questions are to be obtained from a database,cached on a dataset and store the dataset in session object(of the global asax file).questions are read from this session variable and displayed on a form on its form load event.this form has 3 buttons that can enable a user to navigate to the next question,previuos question(s) and another to intentionally end the exam.whenever a user clicks on the back button of the form to access a previously answered question,the previous question is shown but the radio button that was checked as the answer is not checked.Any idea on how can i maintain the checked status for the previously answered questions?
-
Am currently working on my end of semester project (online examination system )where questions are to be obtained from a database,cached on a dataset and store the dataset in session object(of the global asax file).questions are read from this session variable and displayed on a form on its form load event.this form has 3 buttons that can enable a user to navigate to the next question,previuos question(s) and another to intentionally end the exam.whenever a user clicks on the back button of the form to access a previously answered question,the previous question is shown but the radio button that was checked as the answer is not checked.Any idea on how can i maintain the checked status for the previously answered questions?
mbams wrote:
Any idea on how can i maintain the checked status for the previously answered questions?
So you don't record and persist the answers they provided to the questions?
only two letters away from being an asset
-
Am currently working on my end of semester project (online examination system )where questions are to be obtained from a database,cached on a dataset and store the dataset in session object(of the global asax file).questions are read from this session variable and displayed on a form on its form load event.this form has 3 buttons that can enable a user to navigate to the next question,previuos question(s) and another to intentionally end the exam.whenever a user clicks on the back button of the form to access a previously answered question,the previous question is shown but the radio button that was checked as the answer is not checked.Any idea on how can i maintain the checked status for the previously answered questions?
mbams wrote:
store the dataset in session object
First of all, dont do this. Why do you have to set an Entire detaset in session, rather you store in database and get when required.
mbams wrote:
whenever a user clicks on the back button of the form to access a previously answered question
Well, in your case, as I said, always store user's input to the database. Use <a href=nextpage.aspx> to ensure everything to be in the history. If you really require the back functionality you should use <a > tag. Hope you are getting me. :thumbsup:
Abhishek Sur
My Latest Articles **Create CLR objects in SQL Server 2005 C# Uncommon Keywords Read/Write Excel using OleDB
**Don't forget to click "Good Answer" if you like to.