Testing Lingo
You can test Lingo commands to see how they work by entering them in the Message window and
observing the results. When you enter a command in the Message window, Director executes the
command immediately, regardless of whether a movie is playing.
To test a one-line Lingo statement:
Type the statement directly in the Message window.
1
Press Enter (Windows) or Return (Macintosh). Director executes the statement.
2
If the statement is valid, the Message window displays the result of the statement in the Output
pane at the bottom of the window. If the script is invalid, an alert appears.
For example, if you type the following statement into the Message window:
put 50+50
and press Enter (Windows) or Return (Macintosh), the result will appear in the Output pane:
-- 100
If you type the following statement into the Message window:
the stagecolor = 255
and press Enter (Windows) or Return (Macintosh), the Stage will become black.
You can test multiple lines of Lingo all at once by copying and pasting Lingo statements into the
Message window or by pressing Shift-Return after each line of Lingo.
To execute multiple lines of Lingo by copying and pasting:
Copy the lines of Lingo to the clipboard.
1
Enter a blank line in the Message window.
2
Paste the Lingo into the input pane of the Message window.
3
Place the insertion point at the end of the last line of Lingo.
4
Press Control+Enter (Windows) or Control+Return (Macintosh). Director finds the first blank
5
line above the insertion point and executes each line of Lingo after the blank line in succession.
To enter multiple lines of Lingo manually:
Enter a blank line in the Message window.
1
Enter the first line of Lingo.
2
Press Shift+Return at the end of the line.
3
Repeat steps 2 and 3 until you have entered the last line of Lingo.
4
Press Control+Enter (Windows) or Control+Return (Macintosh). Director finds the first blank
5
line above the insertion point and executes each line of Lingo after the blank line in succession.
You can test a handler without running the movie by writing the handler in a Movie Script or
Behavior Script window, and then calling it from the Message window.
430
Chapter 16
Need help?
Do you have a question about the DIRECTOR MX-USING DIRECTOR MX and is the answer not in the manual?
Questions and answers