Liberty BASIC Help Online

Using the Runtime Engine
Notice:  This part of the help file describes a feature of the registered version of Liberty BASIC.  Although the runtime engine described below does come with the shareware version, it is only usable by registered users of Liberty BASIC who have purchased the Gold License.  When you register Liberty BASIC, Shoptalk Systems will provide you with a password to upgrade your copy of Liberty BASIC to the registered version.
The RUN400.EXE runtime engine will allow you to create standalone programs from your Liberty BASIC *.TKN files.  This means that your programs can be run on computers that do not have the Liberty BASIC language installed.  To use the runtime engine, you must have the gold license registered version of Liberty BASIC.
The runtime engine will automatically run a *.TKN file of the same filename as the runtime engine. If you make a copy of RUN400.EXE named MYPROG.EXE, then you must name your *.TKN file as MYPROG.TKN. 
Using RUN400.EXE
First make a *.TKN file from your *.BAS file (see Creating a Tokenized File).
Preparing for distribution
You can share or sell programs that you write in Liberty BASIC.  No fee or royalty payment is necessary.  The only requirements are:
a) That you limit the files that you distribute to the list below.  These files can be found in the directory in which you have installed Liberty BASIC. If you cannot see all of these files in "My Computer" or "Windows Explorer", it is likely that your folder options are configured to hide system files. Go to the TOOLS menu of Explorer and choose FOLDER OPTIONS. Click the VIEW tab and look for the option to "Show all files" in the "Hidden Files" section. Be sure that this option is checked. Here is a list of the files:
b)You must rename a copy of RUN400.EXE to your liking. This is recommended. Try to create a unique name so that it will be unlikely for any File Manager associations to conflict. If you rename RUN400.EXE to MYPROG.EXE, then renaming your *.TKN file to MYPROG.TKN will cause it to be automatically run when the runtime engine starts.
c) You can also replace the icon for RUN400.EXE with one of your own design. Use the icon editor from the Setup menu in the Liberty BASIC editor. This step is optional. Icons for use with the Liberty BASIC runtime engine can contain only 16 colors.
Important: Make sure that when your program is finished running that it terminates properly with an END statement.  Otherwise your program's windows may all be closed, giving the illusion that it has stopped running.
Your Distribution Packet
Your program's TKN file, plus run400.exe (rename to match your TKN), and all of the other files in the list above must be included in your distribution. You must also include any other files used by your program, such as data files, text files and bitmaps. If all of these files are distributed together, then someone who does not have the Liberty BASIC language installed on his computer can run your program by clicking on its icon, or by double clicking on the EXE name in the list in "My Computer" or "Windows Explorer."
Image runtime.GIF
Additional Distribution Information for Port I/O
If your application uses INP() and/or OUT to control hardware ports, you will need to distribute and install certain files on your user's system.  For detailed information, see Port I/O.
Liberty BASIC stores default information in a very small text file named LBASIC4.INI.  This file is also read by the runtime engine (RUN400.EXE) if it is present.  One of the things that LBASIC4.INI manages is the default font used for the the Liberty BASIC development environment and for the runtime engine.  If you want your distributed application to use the same font that is set for the Liberty BASIC development environment, then include the LBASIC4.INI file with your application.  If you want text printed to the printer to use the same printer font that is in use by the Liberty BASIC development environment, then include the LBASIC4.INI file with the distribution.
Installing a Liberty BASIC Program
You can distribute your programs on a set of disks or on a CDROM and ask the user to copy them to his hard drive.  You can also place all of the files into a zip archive.  Thi