EasyManua.ls Logo

Mitsubishi Electric CR750-Q - Page 306

Mitsubishi Electric CR750-Q
730 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
4-286 Detailed explanation of command words
4MELFA-BASIC V
Select Case (Select Case)
[Function]
Executes one of multiple statement blocks according to the condition expression value.
[Format]
[Terminology]
<Condition> Describe a numeric operation expression.
<Expression> Describe an expression using the following format. The type must be the same as the
condition expression.
*IS <Comparison operator> <Constant>
*<Constant>
*<Constant> To <Constant>
<Process> Writes any command (other than the GoTo command) provided by MELFA-BASIC V.
[Reference Program]
1 Select MCNT
2 M1=10 ' This line is not executed
3 Case Is <= 10 ' MCNT <= 10
4 Mov P1
5 Break
6 Case 11 'MCNT=11 OR MCNT=12
6 Case 12
7 Mov P2
8 Break
9 Case 13 To 18 '13 <= MCNT <= 18
10 Mov P4
11 Break
12 Default ' Other than the above.
13 M_Out(10)=1
14 Break
15 End Select
Select[] <Condition>
Case[]<Expression>
[<Process>]
Break
Case[]<Expression>
[<Process>]
Break
:
Default
[<Process>]
Break
End[]Select

Table of Contents

Related product manuals