IT SOLUTIONS
Your full service technology partner! 
-Collapse +Expand
To/From Code
-Collapse +Expand Cross Ref Guide
-Collapse +Expand Members-Only
Sign in to see member-only pages.
   ► KBTo/From GuidesCorel Paradox  Print This     

If Statement (Corel Paradox and Java Cross Reference Guide)

By Mike Prestwood

Corel Paradox versus Java: A side by side comparison between Corel Paradox and Java.

 
Statements
 

Common statements such as if statements, loops, etc.

If Statement

[Other Languages] 
Corel Paradox:   If..Else..EndIf, or switch

ObjectPAL supports a simple If...Else...EndIf statement.

Notice ObjectPAL does not support an ElseIf feature as part of an if statement. Instead use a switch statement

Syntax Example:  
'Does ObjectPAL evaluate the math correctly? No!
If (.1 + .1 + .1) = .3 Then
  msgInfo("", "Correct")
Else
  msgInfo("", "Not correct")
EndIf
 
'Switch statement example.
switch
case x = "Nate": MsgInfo("", "Hi Nate")
case x = "Felicia": MsgInfo("", "Hi Felly")
  otherwise: MsgInfo("", "Who are you?")
endSwitch
Java:   if..else if..else

Syntax template:

if (expression) {
  expression1_true_code;
} else if (expression2) {
  expression2_true_code;
} else {
  otherwise_code;
}
Syntax Example:
if ((.1 + .1 + .1) == 0.3) {
  System.out.println("Correct");
} else {
  System.out.println("Not correct");
}












Go ahead!   Use Us! Call: 916-726-5675  Or visit our new sales site: 
www.prestwood.com


©1995-2024 Prestwood IT Solutions.   [Security & Privacy]