Chronology Current Month Current Thread Current Date
[Year List] [Month List (current year)] [Date Index] [Thread Index] [Thread Prev] [Thread Next] [Date Prev] [Date Next]

powerful BASIC implementation (low incremental cost)



At 10:30 AM 2/8/01 -0500, Ludwik Kowalski wrote:
I would appreciate help from somebody who remembers
how to allocate more memory to True Basic.

To answer a slightly different question: Perhaps you would be happier with
a BASIC implementation that didn't have this limitation.

In particular I have in mind the one that comes hidden inside excel. It
seems to be a fully-featured Visual Basic implementation, and the price is
right. (It's not free for all, but it's paid for if you've already got
excel.)

1) In my version you get started by
Tools --> Macro --> Visual Basic Editor (Alt-F11)
but I seem to recall that the incantation is slightly different in other
versions of excel; you may have to rummage through the menu bars.

2) Next you need to say
View --> Immediate Window (Ctrl-G)
and in that window you can type "print 1+2+3" and it will answer "6".

3) To get serious you say
Insert --> New Module
and in the Module window you type something like
Sub main()
hs = 2 ^ (1 / 12) ' half step
Debug.Print "Note", "Ratio", "Frequency"
For ii = 0 To 12
Debug.Print ii, Round(hs ^ ii, 4), Round(440 * hs ^ ii, 4)
Next ii
End Sub
and to run it you either hit
Run --> Run (F5)
or go to the immediate window (Ctrl-G) and type "main".

4) Note the use of Debug.Print where you would expect to see just
Print. That's probably about the only thing you would have to change to
get True Basic programs to run under this Visual Basic; otherwise just
paste 'em in, or
File --> Import --> c:\whatever\foo.bas

5) OTOH there's a lot of powerful features in this VB that True Basic never
dreamed of.

6) I've seen computers where the Office installation didn't include
installing the help files for this embedded VB feature. It's rather easy
to fix this by using the Office distribution CD to do an incremental install.