Basic4ppc

Last updated
B4x
Paradigm Procedural programming and Event-driven
Designed by
  • Anywhere Software
  • Erel Uziel, CEO
First appeared2005;18 years ago (2005)
Typing discipline Static, Weak
OS
Website www.b4x.com
Dialects
  • b4a - Android
  • b4i - iOS
  • b4j - desktop with Java
  • b4r - Arduino
Influenced by
Visual Basic

Basic4ppc (pronounced "Basic for PPC") is a programming language originally for Pocket PC handheld computers running Windows Mobile operating system, by Anywhere Software. Since 2014, B4x ("B for x") was renamed, and currently, 2023, supports multiple devices and their OS, including desktop and mobile solutions with development adaptions for these environments. [1] The language is based on a BASIC-like syntax, taking advantage of Microsoft's .NET technology, to allow additional libraries, graphical user interface design of windows forms, rapid application development (RAD), and .NET framework compatible compilation. The language implements a unique way of adding objects to a program without being object-oriented. Its advantages are simplicity, development pace and the integration with .NET framework. A special version of the integrated development environment (IDE) allows developing straight onto the Windows Mobile device or. With the demise of Windows Mobile operating system and the devices running it Basic4PPC came to the end of its life in about 2012. For owners of Basic4PPC it remains a useful Windows-desktop BASIC compiler as it runs code directly in the Windows environment and it can compile a project to a Windows 'exe' file for use as a Windows program.

Contents

History (major versions)

Android

In 2010 a version for Android phones/tablets was released, this is a separate environment working along the same lines and the language is "basic" like and can be compiled to Android devices. [4]

Language features

Dual development platform: Basic4ppc allows development straight on the handheld device via a fully compatible Device IDE. Code written on either device or desktop IDEs is identical for both platforms and operating systems. Compilation, however, must target either device or desktop, due to the difference in the operating system.

Compilation available in four modes: Windows executable, Device executable for Pocket PC (with and without AutoScale), Desktop executable, and Smartphone executable (for mobile phones running Windows Mobile OS). Compiled .EXE files require .NET 2.0 framework to be installed on the target machine. This is usually the case with Windows XP SP2 and later, but has to be manually taken care of with earlier versions.

Additional libraries: based on the Microsoft .NET framework, Basic4ppc can use code inside .NET .dll files after being adapted for Basic4ppc (this can be done by any programmer using Microsoft Development tools). Many such additional libraries exist, most of which are open source, written by users and accessible via the Basic4ppc forum.

Merging: Additional libraries code is merged into the main executable almost always. This way a single file can be deployed.

Characteristics

Basic4ppc is procedural, structural, implementing a partial object-oriented programming model. Syntax is similar to common Basic dialects, most influenced by Visual Basic. It supports events. Like most modern languages, the development environment supplies graphical user interface design tools. Users build applications using the drag and drop, component based UI. This is possible on both Device and Desktop, being unique in this ability.

Regular flow structures, such as if…then and for…next are supported, as in many other Basic versions.

Reserved words: Basic4ppc includes a vast number of reserved words. This is because of variable declaration scope.

Variables can be local (accessible throughout a subroutine), global (accessible throughout a module) or public (accessible throughout a program). All variables are typeless. This means you can write the following code:

SubApp_StartnumA="Five "numB="5"numC=6SUM1=numA&numB'remark: = "Five 5"SUM2=numB+numC'remark: = 11EndSub

There is no need to declare variables explicitly.

Subroutines (called "Sub") are the most basic unit of code. All code must be written inside subroutines. Subroutines can return a value.

Direct Naming Reference: All internal controls can be accessed directly and passed as parameters to subroutines by specifying their name expressed as a string. This lets the programmer the ability to pass controls as parameters without knowing in advance the control that is to be passed, and without having to deal with either pointers nor with object oriented programming.

AutoScale mode allows developing for different screen resolution having the language taking care of the adjustments needed in UI appearance.

Example code

Here is an example of the language: Code snippet that displays a message box "Hello, World!" as the application starts, without any forms being loaded:

SubApp_StartMsgBox("Hello, World!")EndSub

Libraries

Based on Microsoft's .NET technology, Basic4ppc supports .NET .DLLs with some minor adjustments. This allowed users to create a lot of open-source libraries, downloadable at the Basic4ppc forum, usually with complete source code. As with many other programming languages, additional libraries include most of the real-world language functionality. Additional libraries cover subjects such as graphics, databases, user interface, GPS, barcode readers and peripheral devices, debug, connectivity (bluetooth, wifi, and data-transfer protocols such as http, ftp and so on), XML, and more.

Related Research Articles

An integrated development environment (IDE) is a software application that provides comprehensive facilities to computer programmers for software development. An IDE normally consists of at least a source code editor, build automation tools, and a debugger. Some IDEs, such as NetBeans and Eclipse, contain the necessary compiler, interpreter, or both; others, such as SharpDevelop and Lazarus, do not.

VBScript is an Active Scripting language developed by Microsoft that is modeled on Visual Basic. It allows Microsoft Windows system administrators to generate powerful tools for managing computers without error handling and with subroutines and other advanced programming constructs. It can give the user complete control over many aspects of their computing environment.

<span class="mw-page-title-main">Liberty BASIC</span>

Liberty BASIC (LB) is a commercial computer programming language and integrated development environment (IDE). It has an interpreter, developed in Smalltalk, which recognizes its own dialect of the BASIC programming language. It runs on 16- and 32-bit Windows and OS/2.

In computing, cross-platform software is computer software that is designed to work in several computing platforms. Some cross-platform software requires a separate build for each platform, but some can be directly run on any platform without special preparation, being written in an interpreted language or compiled to portable bytecode for which the interpreters or run-time packages are common or standard components of all supported platforms.

<span class="mw-page-title-main">Visual Basic (.NET)</span> Object-oriented computer programming language

Visual Basic (VB), originally called Visual Basic .NET (VB.NET), is a multi-paradigm, object-oriented programming language, implemented on .NET, Mono, and the .NET Framework. Microsoft launched VB.NET in 2002 as the successor to its original Visual Basic language, the last version of which was Visual Basic 6.0. Although the ".NET" portion of the name was dropped in 2005, this article uses "Visual Basic [.NET]" to refer to all Visual Basic languages released since 2002, in order to distinguish between them and the classic Visual Basic. Along with C# and F#, it is one of the three main languages targeting the .NET ecosystem. Microsoft updated its VB language strategy on 6 Feb 2023 stating that VB is a stable language now and Microsoft will keep maintaining it.

C++Builder is a rapid application development (RAD) environment, originally developed by Borland and as of 2009 owned by Embarcadero Technologies, for writing programs in the C++ programming language currently targeting Windows, iOS and for several releases, macOS and Android C++Builder combines the Visual Component Library and IDE written in Object Pascal with multiple C++ compilers. Most components developed in Delphi can be used in C++Builder with no or little modification, although the reverse is not true, but this constraint is valid only for source code. Binary code generated by Delphi can easily be linked to binary code generated by C++Builder and vice versa to generate an executable written in both Object Pascal and C++. With this approach, C++ can be called from Object Pascal and vice versa. Since both Delphi and C++ use the same back end linker, the debugger can single step from Delphi code into C++ transparently.

A cross compiler is a compiler capable of creating executable code for a platform other than the one on which the compiler is running. For example, a compiler that runs on a PC but generates code that runs on an Android smartphone is a cross compiler.

<span class="mw-page-title-main">Delphi (software)</span> General-purpose programming language and a software product

Delphi is a general-purpose programming language and a software product that uses the Delphi dialect of the Object Pascal programming language and provides an integrated development environment (IDE) for rapid application development of desktop, mobile, web, and console software, currently developed and maintained by Embarcadero Technologies.

Compact Application Solution Language (CASL) is a programming language used to create computer programs for Palm OS, and Microsoft Windows desktops, laptops, and Pocket PCs with Windows Mobile. It is published by WAGWARE Systems, Inc., and Brainyware, LLC.

<span class="mw-page-title-main">Visual Basic (classic)</span> Event-driven programming language

The original Visual Basic is a third-generation event-driven programming language from Microsoft known for its Component Object Model (COM) programming model first released in 1991 and declared legacy during 2008. Microsoft intended Visual Basic to be relatively easy to learn and use. Visual Basic was derived from BASIC and enables the rapid application development (RAD) of graphical user interface (GUI) applications, access to databases using Data Access Objects, Remote Data Objects, or ActiveX Data Objects, and creation of ActiveX controls and objects.

<span class="mw-page-title-main">Adobe AIR</span> Cross-platform runtime system for building rich web applications

Adobe AIR is a cross-platform runtime system currently developed by Harman International, in collaboration with Adobe Inc., for building desktop applications and mobile applications, programmed using Adobe Animate, ActionScript, and optionally Apache Flex. It was originally released in 2008. The runtime supports installable applications on Windows, macOS, and mobile operating systems, including Android, iOS, and BlackBerry Tablet OS.

<span class="mw-page-title-main">FutureBASIC</span>

FutureBasic is a free BASIC compiler for Apple Inc.'s Macintosh.

<span class="mw-page-title-main">GLBasic</span> Commercial BASIC programming language

GLBasic is a commercial BASIC programming language that can compile to various platforms including Windows, Linux, Mac OS X, and some handheld devices. The language is designed to be simple and intuitive.

<span class="mw-page-title-main">Qt Creator</span> QT development environment

Qt Creator is a cross-platform C++, JavaScript and QML integrated development environment (IDE) which simplifies GUI application development. It is part of the SDK for the Qt GUI application development framework and uses the Qt API, which encapsulates host OS GUI function calls. It includes a visual debugger and an integrated WYSIWYG GUI layout and forms designer. The editor has features such as syntax highlighting and autocompletion. Qt Creator uses the C++ compiler from the GNU Compiler Collection on Linux. On Windows it can use MinGW or MSVC with the default install and can also use Microsoft Console Debugger when compiled from source code. Clang is also supported.

Dart is a programming language designed by Lars Bak and Kasper Lund and developed by Google. The programming language is designed for client development such as for the web and mobile apps, and it can also be used to build server and desktop applications.

<span class="mw-page-title-main">Mono (software)</span> Computer software project

Mono is a free and open-source .NET Framework-compatible software framework. Originally by Ximian, it was later acquired by Novell, and is now being led by Xamarin, a subsidiary of Microsoft and the .NET Foundation. Mono can be run on many software systems.

<span class="mw-page-title-main">Xojo</span> Programming environment and programming language

The Xojo programming environment and programming language is developed and commercially marketed by Xojo, Inc. of Austin, Texas for software development targeting macOS, Microsoft Windows, Linux, iOS, the Web and Raspberry Pi. Xojo uses a proprietary object-oriented language.

Basic4Android is a rapid application development tool for native Android applications, developed and marketed by Anywhere Software Ltd.

<span class="mw-page-title-main">B4X</span>

B4X is a suite of rapid application development IDEs and proprietary programming language that allows the creation of applications on the following platforms: Google Android, Apple iOS, Java, Raspberry Pi and Arduino. Although the B4X syntax is very similar to BASIC, it is an entirely new language.

This page details the history of the programming language and software product Delphi.

References

  1. "Cross platform RAD". b4x.
  2. "New domain: b4x.com". b4x. Nov 25, 2014.
  3. "Cross platform RAD development tools". b4x.
  4. "B4A – The simple way to develop native Android apps". b4x.