Computer Science Canada Errortraping |
Author: | Jai_eun [ Mon Jan 12, 2009 8:58 pm ] | ||||
Post subject: | Errortraping | ||||
I want to make an error trap for all my if statements below but i want them all to give the same message i tried declaring them as one variable but it didnt work is there a way to error trap all of them without having to repeat the trap over again for eah if statement sorry i couldnt figure out the syntax method for posting my code because it does not work for some reason
Mod Edit: Remember to use syntax tags! Thanks ![]()
|
Author: | The_Bean [ Mon Jan 12, 2009 9:10 pm ] | ||
Post subject: | Re: Errortraping | ||
You can hold all the the answers they give in 1 array, and hold all the correct answers in another array. Then you can quickly go through everything with a 'for' loop and check every answer to see if it is correct. To use syntax tags:
|