Forum guidelines
AuthorQuestion
question paper based on MCQs
Posted on: 04 Apr 2011
hey! guys i want to make a question paper that is based on MCQs. (in c#) user select one ov the option and it should tell that answer is right or wrong and at the end of that paper it should also show the result that how much user score...

plz give me idea . i want to make it in windows application forms......

AuthorReply
Re: question paper based on MCQs
Posted on: 05 Apr 2011  
By MCQ if you mean multiple choice questions, then you can do it like this:

1) Design a user interface with the question as a Label (or readonly TextBox) control,

2) Add 4 radiobuttons or checkboxes representing each of the options and a button to submit the answer.

3) When the user clicks the submit button after selecting the options, the code in your program should compare the selected answer with the actual answer (this may be stored in database so you can retrieve it from the database and compare)

4) Based on the result of comparison, increment the score.

5) Repeat above steps for n questions.

6) Display final score.

Note, above listed steps are just a basic idea, you can build on that to make it more complex.

Hope this helps,
Mamta

Re: question paper based on MCQs
Posted on: 05 Apr 2011  
thanks for ur guidelines it will be very useful for me .. how can i write mcqs in sql server i means i can only use table in sql.. can i do it without sql server????
Re: question paper based on MCQs
Posted on: 05 Apr 2011  
what code will be for the "NEXT" BUTTON ?/ next button is for to show new question in new form 

(here i tried many times to upload the image but that is not uploading ) here i skectch so u understand my point .





any quetion here( what is .net)
                      a) a framework
                      b) a language
                      c) an editor

(user selct the option ) then click on next button 

what code will be for next button ? it can be for n question?????

Re: question paper based on MCQs
Posted on: 06 Apr 2011  
Although you can use any other approach to store the questions and answers (such a text file for eg), an Access or SQL Server database would be best suited for this scenario.

The code for the next button will include, retrieval of next question and options from the data source (file/database), if any are present. If you have reached the last question, clicking the next button can confirm whether user wants to end the exam, if yes, then display the calculated score.
It would be easy to show the code here but if you really want to learn and grow, you should try implementing yourself based on above hints.

Re: question paper based on MCQs
Posted on: 07 Apr 2011  
thnks for ur guideline 

 i make it through windows form  its working .. but  i want to close the previous form when new form open ... and also i want to count the score. ... how to code for score all the mcqs?????


Re: question paper based on MCQs
Posted on: 18 Apr 2011  
now i want to make it in sql server to retrive QUESTION from there ... and there must appear all question in one windows form...... ... i share my idea but dnt know how it will be work ... there will be 2 coloumn .. in first column there will be quesion num and in 2nd option ov answer will be match with first column ... how it will be work plz guide me , help me thanks

SPONSORED BY

Custom Software Development
MCN is your source for developing solutions involving websites, mobile apps, cloud-computing, databases, BI, back-end services and processes and client-server applications.