Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

PowerBasic and Python

25 views
Skip to first unread message

Soonioj

unread,
Jul 21, 2003, 6:20:01 AM7/21/03
to
Hi everyone.

For quite some time I've playing around with Python, which (until now)
perfectly suited my programming needs.

The thing is, i now need to code (for numerous reasons...) small and
fast utilities (some for DOS, some for Windows). Why small and fast?
(Why not?) But for a prosaic reason: to run on old-slow-small PCs.

Python is wonderful for the kind of things I have to produce; little
apps for retrieving Web pages, stripping tags, mailing, organizing
info ...etc...
But Python is s-l-o-w and the size issue is not auspicious (i actually
use py2exe to prevent installing Python on each PC, but a
"Hello,World!" prog is 56kb with a 800kb runtime DLL behind it, as for
GUI, a wxPython .exe is ~300kb with 8Mb of runtime DLLs...)

I've heard wonderful things about PowerBASIC: speed,size and good GUI
tools.
My question (as I have little/almost none BASIC experience):
is it easy to code (Power)BASIC to perform similar Python functions?
(append lists, work with arrays, database connectivity)
Is there any "catch" to create small-fast .exe in PB (learning
ASM...etc...)?
Does PowerBASIC for windows also compiles console programs?

Thank you for your time.

Charles Kincaid

unread,
Jul 21, 2003, 9:33:55 AM7/21/03
to
soo...@yahoo.co.uk (Soonioj) wrote in
news:78476353.03072...@posting.google.com:

> Hi everyone.

Hi.

> For quite some time I've playing around with Python, which (until now)
> perfectly suited my programming needs.

I have been planning to take a look at Python but have been to busy with
PB, php, ASP, and VB projects. I heard that it has some similarities to
php.

> "Hello,World!" prog is 56kb with a 800kb runtime DLL behind it, as for
> GUI, a wxPython .exe is ~300kb with 8Mb of runtime DLLs...)

You would have the same results with VB. PB produces small executables
with no runtime. Now any DLL's you call in your program must be
included.

> I've heard wonderful things about PowerBASIC: speed,size and good GUI
> tools.
> My question (as I have little/almost none BASIC experience):
> is it easy to code (Power)BASIC to perform similar Python functions?
> (append lists, work with arrays, database connectivity)

All you mention is included in PB except the database stuff. There is a
good DAO example on the PB web site in the developer forums. I have used
it and will (when I get time) port that over to ADO.

> Does PowerBASIC for windows also compiles console programs?

There is a GUI compiler and a Console Compiler. It is possible to do
some console work with the GUI compiler and there are a number of
examples of the Console Compiler poping up GUI dialogs. There is also a
DOS compiler for when you don't have any version of Windows running.
i.e. DOS before version 7.

Simple? Well BASIC stands for
Beginners
All-purpose
Symbolic
Instruction
Code

--
ATB

Charles Kincaid

JQP

unread,
Jul 24, 2003, 4:10:20 PM7/24/03
to
"Soonioj" <soo...@yahoo.co.uk> wrote in message
news:78476353.03072...@posting.google.com...

> I've heard wonderful things about PowerBASIC: speed,size and good GUI
> tools. My question (as I have little/almost none BASIC experience):
> is it easy to code (Power)BASIC to perform similar Python functions?

Coming from an OO language and without any pre-existing BASIC experience,
this may be more to your liking: www.freepascal.org

- Object oriented
- Broad platform support (DOS/Windows/OS2/Linux/FreeBSD)
- Small executable size
- Superior code quality (compared to PB)
- Free

Kenton W. Mellott

unread,
Aug 1, 2003, 9:53:51 PM8/1/03
to
Soonij,

Personally I consider the DOS version 3.5 as being quite effective and
fast in the resulting program. Even in a DOS window though, there is a
limitation on the size of file the IDE can handle. But since one can
INCLUDE
up to 5 other files as part of the same program code, plus LINK binary files
with routines already compiled by PowerBASIC, there are some work arounds.

I have to admit though that Windows programming leaves me cold in the
amount of the commands that one has to do to get straight to even get a
basic inter-action with the user. Debugging it gets to be a real pain to
me.
Most of the time I only wish to work math, read and control a I/O board, or
clear-up or edit data files, or the likes anyway.

Sincerely,

Gregory D. MELLOTT

"Soonioj" <soo...@yahoo.co.uk> wrote in message
news:78476353.03072...@posting.google.com...

sinewave

unread,
Aug 1, 2003, 10:18:54 PM8/1/03
to
hi Gregory and Soonioj:

> I have to admit though that Windows programming leaves me cold in the
> amount of the commands that one has to do to get straight to even get a
> basic inter-action with the user.

FWIW i wrote a "console I/O" template which allows basic screen I/O using
PB's *WINDOWS* compiler.

regards,
phil :)

Michael Mattias

unread,
Aug 2, 2003, 7:30:26 AM8/2/03
to
"sinewave" <no...@nowhere.com> wrote in message
news:oprs891s...@10.0.0.1...

So did PowerBASIC, Inc. They call it the Console Compiler. You can use LINE
INPUT, PRINT, LOCATE and most of the other MS-DOS BASIC commands with
minimal "mind shift."

MCM


sinewave

unread,
Aug 2, 2003, 3:55:54 PM8/2/03
to
> So did PowerBASIC, Inc. They call it the Console Compiler.

yes Michael... however i just wrote my own functions (cStartup, cTitle,
cCleanup, cColor, cClear, cLocate, cInput, and cPrint)... the largest of
these is only 6 lines. PB/CC is good for advanced routines... but for basic
console I/O i see no point.

regards,
phil

Kenton W. Mellott

unread,
Aug 10, 2003, 3:29:42 AM8/10/03
to
Sinewave,

Send me a copy of your code, if you might.

Sincerely,

Gregory D. MELLOTT


"sinewave" <no...@nowhere.com> wrote in message

news:oprtamzg...@10.0.0.1...

sinewave

unread,
Aug 11, 2003, 7:23:14 PM8/11/03
to
> Send me a copy of your code, if you might.

sure thing Gregory... i just sent it in the mail.

regards,
phil

Robert Wolfe

unread,
Jan 16, 2019, 1:10:39 AM1/16/19
to
On 7/21/03 3:20 AM, Soonioj wrote:

> Hi everyone.

Greetings!

> I've heard wonderful things about PowerBASIC: speed,size and good GUI
> tools.
> My question (as I have little/almost none BASIC experience):
> is it easy to code (Power)BASIC to perform similar Python functions?
> (append lists, work with arrays, database connectivity)
> Is there any "catch" to create small-fast .exe in PB (learning
> ASM...etc...)?
> Does PowerBASIC for windows also compiles console programs?

There is a version of PowerBASIC that is specifically for console
applications in Windows. It is PowerBASIC/CC (CC = console compiler).
The current version is 6.04 and it what I use when I need to code
Windows 32-bit console applications. I also have PB/DOS 3.5, which is
the DOS version of their software when i need to code stuff for DOS (in
my case, OS/2). Both of these products are excellent, but if you are
going to code a console applications for a Win64 environment, PB/CC is
by far your best choice if you wish to go this route. YMMV, however.
0 new messages