| 
              
                
                  | 
                      
                        
                          |  | THE HYPERCARD CENTER |  
 |  
                    |  |  Note: This is a work in progress and many formatting issues have been fixed. Read more about the project on the home page. if (single-statement)if trueOrFalse then statements ¬    [else statements] if trueOrFalse then statements [else if trueOrFalse then statements] [else statements]
 The single-statement ifstructure tests for a condition and executes one statement if the condition is true. You use the optionalelse iforelseform to run other  blocks of code in case the  condition followingifis false. Because each part of a simple ifstructure is limited to one statement, you don't need anend ifstatement. You can send a one-line ifstructure from the Message box. Examplesif it is empty then exit myHandler ask file "Save information to file:" if it is empty then exit myHandler else saveFile it ask file "Save information to file:" if it is empty then exit myHandler else saveFile it
 Related TopicsPlaceholderstrueOrFalseAny expression that evaluates to the HyperTalk and AppleScript constants trueorfalse. For example: true false the hilite of bg btn "Yes" fld "Zip" contains "95014" the short name of this stack is "Fred"
 statementsAny return-separated list of built-in commands, user-defined handlers, or keywords that are part of a message or function handler. put "Hello world"   -- built-in command get total(field 1)  -- function call global HelpInfo     -- keyword
 
                HyperTalk Reference
               
 |