Home Previous section Next section

QBasic interface

This chapter gives a brief overview of the QBasic interface.

The interface has the following features:
  1. Window displaying the current program

  2. Menu

  3. Name of current program

  4. Window to immediately execute a command

  5. Status bar

  6. Status of Caps Lock and Num Lock

  7. Current line of cursor

  8. Current column of cursor

QBasic interface
QBasic interface

Current program

The current program is displayed in the middle of the screen, and covers most of the QBasic interface.


The menu provides most of the operations for the QBasic editor. Such as opening a file, pasting text, and searching for a string.


      New - Clears the current program

      Open - Loads a program from disk

      Save - Saves the current program to disk

      Save As - Saves the program, but under a different name

      Print - Prints the selected text, current window, or entire program

      Exit - Closes the QBasic interpreter


      Cut - Removes the selected text and stores it in the clipboard

      Copy - Copies the text instead of removing it

      Paste - Adds the text in the clipboard to the current position of the cursor

      Clear - Removes the text without storing it to the clipboard

      New Sub - Enables you to create a new subroutine (see Subroutines and Functions)

      New Function - Enables you to create a new function (see Subroutines and Functions)


      SUBs - Shows the list of current subroutines and functions (see Subroutines and Functions)

      Split - Displays the contents of the current program in two windows. If the window is already split, this hides the second window (NOTE: The text in each window is always the same, even if you alter the text in one window)

      Output Screen - Shows the QBasic output screen.


      Find - Allows you to search for a string of text in the program

      Repeat Last Find - Continues the previous search operation

      Change - Replaces each instance of a string with another string


      Start - Executes the current program

      Restart - Starts from the beginning

      Continue - Continues execution at the current position


      Step - Processes the next command

      Procedure Step - Processes the next command, but does not show QBasic going inside a subroutine or function

      Trace On - Shows the command that is being executed while the program is running

      Toggle Breakpoint - Sets or removes a breakpoint. Use this to have the QBasic interpreter stop when it reaches a specified line in the program

      Clear All Breakpoints - Removes all breakpoints in the program

      Set Next Statement - Allows you to continue execution at the specified line


      Display - Enables you to change display colors, the number of spaces to use for tabs, and whether or not scroll bars are visible

      Help Path - The location of the QBASIC.HLP file

      Syntax Checking - Allows you to have the QBasic editor check the syntax of your program as you type


      Index - List of all QBasic commands, keywords, operators, etc.

      Contents - The table of contents for QBasic help

      Topic - Show help for a specific keyword

      Using Help - Displays information on using QBasic help

      About - Shows information about the QBasic interpreter

Name of current program

The file name of the current program is displayed near the top of the screen in the center. You can change the name by selecting "Save As" on the "File" menu.

Immediately execute a command

QBasic provides a way to execute a command without running the current program. To do so, select the bottom window (under "immediate") and enter a command, then press Enter.

Status bar

The status bar is at the bottom of the screen. It displays a short list commands (<Shift+F1=Help> <F6=Window> <F2=Subs> <F5=Run> <F8=Step>).

When you highlight an item on the menu, the status bar displays a short description of what the item does.

Status of Caps Lock and Num Lock

If Caps Lock is set, a "C" is displayed on the right side of the status bar.

If Num Lock is set, an "N" is displayed on the right side of the status bar.

Current line

On the right side of the status bar, the current line of the cursor is displayed.

Current column

On the right side of the status bar, the current column of the cursor is displayed (immediately after the current line).

Next section

Feel free to distribute this tutorial, upload it to your website, link to it from your site, etc.

Mirror: http://development.freeservers.com/qbtutor