Wednesday, 24 October 2012

Mistaken use of Select Case

When I showed you how to check multiple cases to do the same outcome I accidently used a format found in the language C#. This results in no action being taken.

Below is a short example illustrating the way I showed you and the correct way to do it.

For p = 0 To s.Length - 1
    Select Case s.Substring(p, 1).ToLower()
 
          'correct way to test for multiple cases with same outcome
          'use comma between things you want to do the same action with
          Case "a", "b", "c" : counter = counter + 1
 
          'wrong way to test for multiple cases with same outcome
          'this will not work
          Case "a" : Case "b" : Case "c" : counter = counter + 1
     
     End Select
 Next

Tuesday, 23 October 2012

Half term work

You need to complete the following work over half term.

Corrections to Program one report
Evaluation for Program one - making sure you explain the differences between first and final versions.

Final version of Program two report

Evaluation for Program one - making sure you explain the differences between first and final versions.

Draft version (but complete) of Program three report
Draft Evaluation for Program three