Using Command Window to Change Variable while Debugging (32269)






This article was previously published under Q32269

SUMMARY

The following information pertains to changing the value of a variable while debugging a program in the Macintosh QuickBASIC Interpreter.

Consider the following program:
   LET X% = 100
   LET Y% = 200
   PRINT X%
   PRINT Y%
   END
				
Assume that you have set a breakpoint at the third line. Before continuing the program's execution, you can change the value of any variable by selecting the Command window from the Windows menu and issuing the proper QuickBASIC statement.

For example, to change the value of X% from 100 to 2, do the following:

  1. Select the Command window.
  2. Type the following:

    LET X% = 2

    Now, when Continue is selected from the Run menu, 2 will print for X% and 200 for Y%.

Modification Type: Minor Last Reviewed: 1/9/2003
Keywords: KB32269