Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Special pages
Niidae Wiki
Search
Search
Appearance
Create account
Log in
Personal tools
Create account
Log in
Pages for logged out editors
learn more
Contributions
Talk
Editing
PowerBASIC
(section)
Page
Discussion
English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
==Compilers== PowerBASIC programs are self-contained and use no runtime file to execute. In all versions of the compiler, the applications compile without external libraries, though it can use such libraries if needed. PBDOS creates [[16-bit]] [[DOS MZ executable]] files, while PBWIN and PBCC create [[32-bit]] [[Portable Executable]] (PE) files. ===Turbo Basic=== Borland's Turbo Basic contains extensions to classic BASIC (without breaking compatibility), such as a drawing API and mouse access. Unlike most BASIC implementations of its time, Turbo Basic was a full [[compiler]] which generated native code for MS-DOS. Other implementations were either [[BASIC interpreter|interpreters]], or relied heavily on a [[runtime library]]. The integrated development environment could run a BASIC program internally for traditional BASIC debugging (see sample below), or generate an MS-DOS stand-alone [[.exe|executable file]] that could be run on other systems without the Turbo Basic product or runtime libraries. ====Code example==== <!-- Deleted image removed: [[File:Turbobasic11 01.png|thumb|Turbo Basic 1.1 editing the example code, in the zoomed editor window.]] --><!-- Deleted image removed: [[File:Turbobasic11 02.png|thumb|Turbo Basic 1.1 running the example in the multiple-window IDE.]] --> The following program is an example of the [[ALGOL]]-like BASIC dialect that Turbo Basic supported. Unlike traditional BASIC,{{citation needed|date=February 2018}} which used line numbers and had limited control structures and no support for ALGOL-like subroutines, modern BASIC dialects starting at this period were extended to make the language compatible with modern [[structured programming]] style by making line numbers optional and adding the control structures and subroutine definitions needed for structured programming. <syntaxhighlight lang="qbasic"> INPUT "What is your name?: ", n$ PRINT "Hello "; n$ DO s$ = "" INPUT "How many stars do you want to print"; s FOR i = 1 TO s s$ = s$ + "*" NEXT i PRINT s$ DO INPUT "Do you want to print more stars"; q$ LOOP WHILE LEN(q$) = 0 q$ = LCASE$(LEFT$(q$, 1)) LOOP WHILE q$ = "y" PRINT "Goodbye "; n$ </syntaxhighlight> (<code>s$</code> is a [[string (computer science)|string]] and <code>s</code> is a [[single-precision floating-point format|single-precision floating-point]] (number). They are separate variables.) Like the other Borland products of this era, the code executes within the integrated development environment. ===PowerBASIC for DOS (PBDos)=== PBDOS includes an [[integrated development environment]] (IDE) and supports [[DOS]] 3.30 and all later versions.<ref>{{cite web |title=PowerBASIC 3.5 for DOS |website=PowerBASIC |url=https://www.powerbasic.com/products/pbdos/ |url-status=dead |archive-url=https://web.archive.org/web/20160117225331/https://www.powerbasic.com/products/pbdos/ |archive-date=2016-01-17}}</ref> ===PowerBASIC Console Compiler (PBCC)=== <!-- [[PowerBASIC Console Compiler]] redirects here (to make the PBCC disambiguation work) --> PBCC is a 32-bit compiler for the [[Windows 9x]] series and [[Windows NT]] series of [[operating system]]s, including [[Windows XP]], [[Windows Server 2008]], [[Windows Vista]], and [[Windows 7]]. PBCC applications can use [[dynamic-link library|dynamic-link libraries]] (DLLs). The compiler comes with an [[integrated development environment|IDE]] including an editor and stepping [[debugger]]. No knowledge of Windows programming is required to create character mode or graphical applications with this compiler. PBCC-compiled executables can also be used as [[Common Gateway Interface]] executables (for web servers). PBCC creates only executables, not DLLs. (PBWin β see below β can create both.) ===PowerBASIC Compiler for Windows (PBWin)=== PBWin is a 32-bit compiler compatible with the [[Windows 9x]] series and the [[Windows NT]] series of operating systems, including [[Windows XP]], [[Windows Server 2008]], [[Windows Vista]], [[Windows 7]], [[Windows 8]] ([[Windows 8.1|8.1]]), [[Windows 10]] and [[Windows 11]] <ref>{{cite web |title=PowerBASIC Compiler for Windows |website=PowerBASIC |url=https://www.powerbasic.com/products/pbdll32/ |url-status=dead |archive-url=https://web.archive.org/web/20080308053722/https://www.powerbasic.com/products/pbdll32/ |archive-date=2008-03-08}}</ref> PBWin can create [[dynamic-link library|dynamic-link libraries]]. PBWin applications can read dynamic-link libraries]. PBWin comes with a compiler, [[integrated development environment|IDE]] with editor, and stepping [[debugger]]. ====Dynamic Dialog Tools (DDT)==== You can create an application's [[graphical user interface]] using the [[Windows API]], or by using the built-in DDT language extensions. The group of BASIC statements which wrap [[Windows API]] functions, particularly in the creation and handling of [[dialog box]]es and child controls, is collectively known as Dynamic Dialog Tools. Using DDT requires less coding than to create a similar program using the [[Windows API]]. Using the DDT and the Windows API (known as SDK style as in [[Microsoft Windows SDK]]) are not mutually exclusive. ====Trial versions of compilers==== PowerBASIC renamed PBWin v9.07 and PB/CC v5.07 as "Classic PBWin" and "Classic PB/CC", respectively, and on November 1, 2016, offered them for a short time through their online store as free, no-nag, trial versions along with PBForms v1.0 (PowerBASIC Forms).<ref>PowerBASIC 9 for Windows and PowerBASIC Console Compiler 5: [https://web.archive.org/web/20161005022613/http://shop.powerbasic.com/pages/powerbasic-product-catalog $99 and $89 on 2016-10-05]; [https://web.archive.org/web/20161106163339/http://shop.powerbasic.com/pages/powerbasic-product-catalog $0 and $0 on 2016-11-06]; [https://web.archive.org/web/20161218181204/http://shop.powerbasic.com/pages/powerbasic-product-catalog $0 and $0 on 2016-12-18]; [https://web.archive.org/web/20170228152624/http://shop.powerbasic.com/pages/powerbasic-product-catalog not offered on 2017-02-28].</ref>
Summary:
Please note that all contributions to Niidae Wiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
Encyclopedia:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Search
Search
Editing
PowerBASIC
(section)
Add topic