Error

 BBS: Inland Empire Archive
Date: 06-16-92 (21:00)             Number: 651
From: MATT HART                    Refer#: NONE
  To: CONNON WALTERS                Recvd: NO  
Subj: Error                          Conf: (2) Quik_Bas
 CW>       After compiling the DAD.BAS into a stand-alone '.EXE ', I can run
 CW>       it only from the directory I was in when I compiled it

Make certain all the files for the program exist - are
there any other data files or such?

You can compile the program with /D (Debug) and it will make it larger, but
add better error checking code.  Sometimes, the errors you
described are "masked" errors - errors reported which are
not the real error.  These types of errors are caused by
problems with Dgroup.  If you are compiling from the
command line, make sure your are using /O and linking with
BCOM45 rather than BRUN45.  Common masked errors include
subscript out of range and out of string or stack space.
The /D will catch the subscript out of range errors (and
possibly the others).  You can track string and stack
space, as well as far heap memory, with the FRE statement.
Put:
     PRINT "String Space = ";FRE(0)
     PRINT "Far Heap     = ";FRE(-1)
     PRINT "Stack Space  = ";FRE(-2)

in various places throughout your program.  If any get to
negative - that means big trouble, and you have found your
masked error!  If string space drops below 5K, you may be
in trouble.  If stack space drops below 512 bytes, you are
in trouble.  If the far heap is less than 20K or so, you
are running out of memory.
---
~~ RICK VINDT DIT ER G GOED !!!!
 * Origin: Midnight Micro!  V.32/REL  (918)451-3306 (1:170/600)
Outer Court
Echo Basic Postings

Books at Amazon:

Back to BASIC: The History, Corruption, and Future of the Language

Hackers: Heroes of the Computer Revolution (including Tiny BASIC)

Go to: The Story of the Math Majors, Bridge Players, Engineers, Chess Wizards, Scientists and Iconoclasts who were the Hero Programmers of the Software Revolution

The Advent of the Algorithm: The Idea that Rules the World

Moths in the Machine: The Power and Perils of Programming

Mastering Visual Basic .NET