Switch Case:, Default Usage

  • Hallo All,


    Ex: SET I090 0 // Here to select which case
    Switch I090
    case 0
    A to B
    case 1
    B to A
    Default
    Call Job: Home
    Endswitch


    Here I am changing the value of I090, If I give the value '0' it should travel from A to B or '1' from B to A If I dont give any value for Ex: '5' as there is no case with number '5' it should perform Default operation that is to move home.


    But my default case is not working. I would like to know where is the problem. Thanks in advance.

Advertising from our partners