Clarion (programming language)
|Developer(s)||JPI, Clarion International, SoftVelocity|
|Stable release||9.1 / July 29, 2014|
|Operating system||Microsoft Windows|
|Type||Integrated development environment|
Clarion is a commercial, 4GL, multi-paradigm, programming language and Integrated Development Environment from SoftVelocity used to program database applications. It is compatible with ISAM, SQL and ADO data access methods, reads and writes several flat file desktop database formats including ASCII, CSV, DOS (Binary), FoxPro, Clipper, dBase, and some relational databases via ODBC, MS SQL Server, Sybase SQL Anywhere and Oracle through the use of accelerated native database drivers, and XML, Clarion can be used to output to HTML, XML, plaintext, and PDF, among others.
One of the Clarion Development Environment's primary features is its use of templates which are used in conjunction with a code generator to produce much of the repetitive, time consuming code that is typically required when producing an application. An "embeditor" shows the developer the code that will be generated and embed points where the developer can enter their own hand-code in the context of the template generated code. Clarion programmers can create their own templates, or edit the existing ones.
- 1 History
- 2 Notability
- 3 Criticisms
- 4 Properties
- 5 Use of Templates
- 6 Wide Variety of 3rd Party Extensions / Inter-Language Support
- 7 Database Flexibility
- 8 Learning Clarion
- 9 Flexibility
- 10 Dictionary Abilities
- 11 Hello World
- 12 Programing for Non-Programmers
- 13 The Global Map
- 14 Interop with .NET Libraries
- 15 References
- 16 External links
The first release of the Clarion language was a DOS product called Clarion 1.0 and was first released in April 1986. Clarion was created by Bruce Barrington, one of the founders of healthcare firm "HBO & Company" (later acquired by McKesson Corporation), and a small team of developers. Barrington's goal was to create a language that would be compact and expressive, and would maximize the use of the memory-mapped screen of the IBM PC by creating a screen designer. Version 1 produced pseudocode; the initial release included a screen designer, an interpreter, an editor, and a debugger. Initially it supported databases composed of DAT files and Clarion’s proprietary ISAM file format. Bruce Barrington formed Barrington Systems and released version 1.0.
Clarion 1.0 required the use of a dongle, at a time when industry sentiment was turning against dongles, which was offset by the ability to create royalty-free applications. However the dongle was removed with the release of 1.1.
At the same time, an even more basic version was sold. Called Personal Developer, it was very limited in what the user could do, but was adequate for very basic database applications. And it was a fraction of the cost of Professional Developer 1.x.
Version 2.0, released in May 1988, was known as Clarion Professional Developer, or CPD, and included a component called Designer, which incorporated a data dictionary. CPD generated Clarion code based on the contents of that dictionary and a template called a "model file." Because the model file was a text file, it could be modified (in limited ways) to create custom code. The model file was implemented with the "browse and form" paradigm, where data is initially displayed to the user in list box, and updating is done via a form called via buttons associated with the list. Designer created all the essential of the CRUD (create, read, update, delete) code, and developers could enhance functionality by inserting code at specified points in the generated code, or by hand-coding new procedures. Clarion Professional Developer also introduced Language Extension Modules (LEMs), that could extend the Clarion language using modules compiled in other languages that were built to the LEM format. Clarion Software and many third-party tool developers created LEMs for all purposes, including an extension for connecting to other databases such as dBase, Clipper and Paradox.
CPD 2.x was a database solution with everything required for screens, reports, databases and help files. A version of Clarion 2.x for end-users, Clarion Personal Developer, was also released just for the business user creating his own personal applications. Around the same time period, Clarion released Clarion Report Writer. This was created as both a stand-alone product for end-users of Clarion Personal Developer and users of programs written by developers with CPD, and as a built-in program bundled with Clarion Professional Developer version 2.1 released in 1989.
In 1991 Barrington licensed compiler technology from a company called Jensen & Partners International (JPI).
JPI was founded in 1987 by Niels Jensen, who had earlier (1979 or 1981) been one of the founders of Borland. Philippe Kahn was the marketing personnel who built Borland around the $99 Turbo Pascal compiler. Niels and his team were working on a new compiler technology at Borland when Philippe Kahn decided to buy Wizard C, and call it Turbo C. Niels and several other developers left Borland and started JPI, where they continued to work on their compiler technology, christened TopSpeed, which they bought from Borland for $1.7 million.
Clarion Database Developer 3.0 (CDD) was released in 1993. It was a revolutionary product adding many features and technology that could create programs with a “Windows like” CUA (Common User Access) user interface. Much of the CDD changes fit well into the Windows programming paradigm and laid the groundwork for the future Clarion for Windows product.
The CDD IDE was completely new and based on the JPI IDE. It included many professional programmer quality tools: editor, project system, compiler, linker, visual debugger. Gone was the p-code of CPD. The JPI compiler for the Clarion language produced true machine code EXEs, LIBs and DLLs. Binaries could be compiled for Protected Mode allowing DOS programs to use extended memory breaking the 640KB barrier.
The Clarion 3.0 language was enhanced in many ways, e.g.: new data types (CSTRING, PSTRING, DATE, TIME, USHORT, ULONG), file driver system (e.g. Btrieve, Clarion, Dbase, FoxPro, Paradox), queues (tables) were enhanced, screen processing was enhanced for CUA. Code generation by Models was replaced by “templates” that had more features and were extensible. This allowed generation of much more robust and complex code.
With all this new power came complexity. Many existing users found the transition to CDD difficult. CPD was simple and easy to use which attracted many non-programmers that could build programs by answering questions. CDD was more suited to professional programmers. Programs could still be developed as easily, but the size and vast features of the IDE made it appear complex.
The first 5 patch releases of CDD were buggy to the point of being unusable, which caused so many users to abandon the product that it was nearly a complete disaster for the company. Clarion kept working on CDD and by version 3.007 it was usable.
Version 3.1 named Clarion for DOS (CFD) was released in 1995. This proved much more stable, but by this time there was little interest in DOS development tools. A significant feature was the TopSpeed file driver, an ISAM file format allowing all indexes and multiple data files to be contained in one disk file.
During this time the relationship between Clarion Software and JPI grew closer, and on April 30, 1992, Clarion merged with JPI to form an entity which would eventually be called TopSpeed Corporation. The employees at the TopSpeed Development Centre in London went to work on CDD and ironed out many of the bugs.
TopSpeed released Clarion for Windows version 1.0 (aka CW 1.0) in January 1995. The final 1.003 release was June 1995. The IDE was completely written as a Windows GUI and could produce Win16 EXE and DLL binaries to run under Windows 3.x. The language featured many enhancements required to support the event driven Windows user interface. A Clarion developer could easily create a multithreaded MDI application. CW 1.0 continued the database flexibility added in CDD as well as adding an ODBC driver allowing connection to SQL databases, or any source supported by ODBC.
The DOS monolithic template model was significantly enhanced in CW 1.0 and replaced by a model that allowed a window to use multiple templates (Extension, Control or Procedure templates). For example, in DOS a screen procedure could support browsing a single data table. Under CW 1.0 a Window could use multiple Browse Control Templates each one displaying a different table. This design change was a major improvement in the power of Clarion code generation.
Clarion for Windows version 1.5 (aka CW 1.5) was released September 1995, with the final 1.502 release January 1996. This version added support for creating native Win32 binaries for Windows 95 and Windows NT 4. The same source could target Win16 or Win32. The IDE remained 16-bit but added 32-bit compilers, linker and debugger.
Clarion for Windows version 2 (aka CW20) was released in June 1996, with the final 2.003 release March 1997. CW20 added classic object orientation to the language, including inheritance, encapsulation, virtual methods and overloading. CW20 enhanced 32-bit support, added ActiveX support and enhanced SQL support.
Clarion 4 (aka C4) was released December 1997, with the final 4.002 release May 1998. TopSpeed elected to skip the dreaded version number three (the official explanation was that CW 1.5 "should have been CW 2.0," so CW 2.0 "should have been CW 3.0", so let’s just call the next one version 4). Due to DOS development being dead the name dropped the "for Windows" title.
C4 came with a new template set and class library called "Application Builder Classes" or “ABC”. The original template set generated procedural code, which was becoming increasingly complex. The ABC template set generated far less code, and leveraged the class library, which contained most of the actual logic for windows, browses, forms, etc. C4 enhanced OOP by adding Constructors and Destructors (without parameters).
Clarion 5 (aka C5) was released May 1998, with the final 5.0B release June 1999. The product was split into Professional and Enterprise editions.
Clarion 5.5 (aka C55) was released August 2000, with the final 5.507 release January 2002. C55 added Interfaces to OOP.
Clarion 6.0 (aka C6) was released November 2003, and added direct support for pre-emptive multi-threading.
Clarion 6.1 was released May 2004.
Clarion 6.2 was released May 2005.
Clarion 6.3 as released Jan 2006. Excluding patches this is the final release of the 16 bit Clarion development environment. The use of a 16 bit IDE produced some problems using current Windows technologies (ActiveX, OCX, COM, DOC, ...); however, note that the series 6.x of Clarion produces native Win32 executables (32-bit exes and/or dlls). Previous versions produced both 16-bit and 32-bit executables, the 16-bit support was dropped from the end-user product with version 6.0 of Clarion.
On April 13, 2009 SoftVelocity released Clarion 7 (aka C7). The new IDE will look familiar to SharpDevelop users; SoftVelocity obtained a commercial license for the SharpDevelop code and integrated Clarion's code generation and application generation technology. Major new features (other than the standard modern IDE features lacking in C6) include a build system based on MSBuild and backward compatibility with all releases of Clarion going back to Clarion for Windows 1.5.
C7 is still a Win32 development environment, but a beta .NET version of the Clarion language, called Clarion#, is available. Both Clarion# and C7 share the same IDE, although at present they are shipped as separate products. Unlike C7, Clarion# does not yet have a dictionary editor or application generator. When Clarion# goes gold it is expected that a single IDE will support both Win32 and .NET development.
The new IDE (in Clarion# mode) retains the ability to build .NET applications with VB.NET and C#.
On September 12, 2011 SoftVelocity released Clarion 8. It continues the line of Clarion 7 (the latest release was C7.3).
The actual running version (August 2014) is C9.1.11139, which was released as GOLD -- meaning perceived by the development team as being ready to use as a stable release.
Clarion is historically notable as being one of the first 4GL computer languages, first developed in the 1980's.
To this day, it is used world-wide and remains among the most versatile 4GL ("writes the code for you") and concurrent application development environments available, rivaling many other 4GL environments, including "Magic", and most notably IBM's "Sign-On" 4GL language for their "iSeries", formally known as "AS/400" series of mid-range Computer Ranges.
It has a vibrant community, is used by 1/3rd of the Fortune 500's Top Companies, and has decades of dedicated systemic thought behind it. The SoftVelocity Compiler Team originates from the Borland Compiler Team, which had Niels Rymenams, currently Microsoft's lead Architect of the .NET Environment as part of it's early development team.
Historically, it was the first 4GL Development Environment available for MS-DOS. And it is current. Windows 7 x86 and x64 are fully supported, as are any O/S environments that are able to consume Web-Based content it can deliver.
Thanks to the developer community libraries written in .NET can be consumed in Clarion through the use of the Unmanaged Exports nuget package https://www.nuget.org/packages/UnmanagedExports.
Clarion is a data-centric language, meaning that its primary function is the management and manipulation of data. Thus the language has commands that deal directly with the reading and writing of databases.
Clarion is able to produce as a standalone application an "EXE" that embeds, natively, not only the DLL's or any libraries it might need, but also full database and reporting output requirements it may require. It is unique in that it can produce an EXE that can be sent with no 3rd party installs (like database servers) required.
The Clarion TopSpeed (.TPS) database format is capable of supporting up to 4 dimensions in a single column definition within any table. No version of SQL Server is capable of supporting this at present. This means that it is possible to define a single field, with multiple dimensions, as simply as (of any of the supported data types, which include ALL of the data types supported in most databases), as:
Dimension 5,2,100, 2000
So in ONE field (Column), in this example, you can reference up to 5 x 2 x 100 x 2000 elements, uniquely. In a single row, or record. A Clarion Developer can refer to for example:
Long I# = CUS:DescendantNamesAcrossTheUniverseIdNumber[1,2,51,1500]
A number of International Companies make use of this product as the core of their development, using Clarion's ability to tap into .NET's capabilities with ease, and call any .DLL's methods developed in VB, C#, C++, Delphi, C++ or C.
The Clarion 4GL Application Generator is currently able to produce .NET ASP.NET code as output as well as the other formats it supports, and still data types which have been "pushed under the radar" (un-documented at any level) by Microsoft AND SoftVelocity and are yet are still supported in .NET, for example, the "BSTR" or "BSTRING" data type native to the Windows API.
The Clarion Language is widely advertised with the slogan "Develop Applications 10x Faster".
This is a serious understatement.
Developers using 3GL languages (Delphi, C#, C, C++, VB etc.) are all too well experienced at seeing messages like "Unhandled Exception in...", or "Index out of bounds, index must be positive or zero...", or "System null reference exception at..", or to name just a few, that need to coded specifically to catch. Every single time a new project is undertaken.
Developers who hand-code applications from the ground up have total control -- to introduce all the errors in their logic they like. Based on their level of experience. And over the years these will diminish over time.
And, (in contradiction to the advice given by the book "Code Complete" (C), they will realize over time the benefits (and pitfalls) of using sound, tried and tested code, by using "COPY AND PASTE".
Errors they encounter after having done this will be due to their not renaming variables correctly, not handling edge conditions correctly, not taking into account scenarios that didn't exist in the code they copied, but do exist in the new scenario, and so on. But the "grudge code", the repetitive, mind-numbing code will at least be mostly in place.
Most, if not all developers have at some or other time used this technique -- because it saves... time.
Clarion takes this principle to the next level. It uses tried and tested "code templates" to generate code for you -- except that it does take into account variable names, it does take into account edge conditions, it does take into account the new scenarios. And these "code templates" have been rigorously refined, year after year, to produce rules that will result in code that is reliable, dependable, and has been demonstrated to take care of virtually every conceivable condition you would normally have to code for. By hand.
In effect, Clarion allows you to specify "high level" details, and using the code templates that have been painstakingly developed to handle all of your requirements, generate code that does pretty much exactly what you would have coded by hand.
I say "petty much", because in most cases, it will generate code that takes care of situations that you didn't have the time to think about, but has been taken care of for you. Like... how many developers realize that a "CHANGE" to a record is extremely similar to an "INSERT"? Clarion knows there is.
Or .. how many developers, faced with 100 million records, will code so as to produce "page-loaded" views of the data, and automatically not only provide you with search / location capabilities in the data in your list, but also allow these searches to automatically be "starts with", "contains", "ends with" etc. capable? It's automatic. No coding required. At all.
Or .. how many developers code so as to allow for multiple users to access the same table at the same time, not only from different applications, but from within the SAME application, with each access individually, automatically shielded from the other by virtue of the fact that by simply checking a tiny little "Multi-Threaded" check box on the table definition you were providing for buffered, isolated, thread-safe access to rows in the table, concurrently, from within the same application. And, again, it's automatic. No coding required. At all.
These trivial, yet hopefully thoughtful examples are not even the tip of the tip of the 4GL capabilities the Clarion 4GL Application Generator can do for any developer. Against ANY database. Of ANY size. Clarion is database agnostic. It is not biased towards ORACLE, MICROSOFT, MYSQL etc. (All trademarks recognized).
In the opinion of the writer, this tool affords a 10-20X productivity gain, in the development phase of a project, followed by a 30-50x gain in the ongoing support and enhancement phases. My opinion. Having developed in 12 languages over 25 years.
Clarion's biggest criticism is their close-knit community, which guards its knowledge base, and tends to interchange knowledge only at a price. This price may be having to have purchased Clarion, with a valid license, in order to gain access, or a subscription fee, which is normally required to be renewed annually.
For information. The type that in other language communities is in general freely shared, with very few notable exceptions, which require subscription in order to contribute.
A typical example of this "information hording" , is what is widely considered to be the "Central Repository" of Clarion knowledge, namely "www.clarionmag.com", which requires subscription in order to gain access to articles and contributions made (freely) by other Clarion developers. This in stark contrast to sites such as "www.stackoverflow.com" which provide information in abundance, and at no cost to developers, and provides a healthy interchange of problems and solutions.
No Trial Version Available
There is no trial version, of any Edition of Clarion, at the time of this writing. At all.
This in stark contrast to other mainstream language vendors, which tend to provide trial / evaluation versions of their languages for developers to decide if their offerings will meet their needs or not.
It is not possible to produce a simple "Hello World" program in Clarion, without purchasing a license first.
Clarion's documentation is of a notoriously poor standard, with the mixture of "Enterprise Level" and ".NET" capabilities being intertwined into what appears to be a single, one-serves-all Help Source. Functionality is described (together with code snippets), and shipped with, for example, the WIN32 version of the "Professional Edition", where this functionality is not only not available in the product it was shipped with, but bears no relevance at all. The numerous references to "Clarion 7" within the "Clarion 8" or "Clarion 9" documentation are hardly comforting to the developer making use of these references. Which exist at a "Tutorial" and "Sample Application" level as well. Third party vendors tend to fall into this same trap, where their "application examples" are shipped as is, based on previous versions of Clarion, and require "upgrading" on first compiling to the latest version of Clarion.
In the opinion of the writer, this has led many ardent supporters of the Clarion Language to question quality standards, and has provided Clarion critics with valid reasons with which to reject Clarion as a reliable product capable of meeting its documented capabilities.
Undue Focus on COM
One of the Clarion 9.1's most announced advanced capabilities is the ability to "auto-register" COM objects on demand, so that there is no need to register COM components by means of the "REGSVR32" command prior to their use.
This capability is not only of virtually no consequence to developers who depend on COM, since those that do tend to include COM Object registration as part of their Installation / Setup Applications, but is an example of focus being placed on a technology that is widely considered to be antiquated, and is being phased out, in favor of .NET components.
To emphasize this, consider the use of the Clarion data type BSTRING, which is supported by the Clarion language, but documented nowhere. At all. On the .NET side, it is referred to as "UnmanagedType.BStr", a data type which is required to be "marshalled", or "translated" by virtue of the fact that it does not really fit into the newer .NET picture.
It is a curiosity that Clarion is propounding, as an advanced feature, the continued use of COM as it is, while at the same time, the very mention of this data type has dropped off of the radar, in all Clarion documentation, yet is key to COM interoperability.
For example, on the Clarion side of a .NET DLL call, the so-called "PROTOTYPE" (or declaration of the function/procedure "structure") for a function called "SayHello" could be:
(BSTRING), LONG, PASCAL, RAW, DLL(TRUE)
While on the .NET side (using C#) it would be:
[DllExport("SayHello", CallingConvention = CallingConvention.StdCall)]
private static CWLong SayHello([MarshalAs(UnmanagedType.BStr)])
Which declares the static function, receiving the BSTRING to display, and returning a value, for example 0 or 1, indicating success or failure.
Why make such a fuss about new COM features and then (continue to not mention) BSTRING as a data type?
This data type, clearly critical, is still recognized by Clarion, but in (I would suggest acknowledgment of the phasing out of COM) the Clarion IDE is not available as a data type -- like BYTE, BOOL, CSTRING etc. is.
Clarion, a stunning 4GL Development Environment, has released a product derivative, known as Clarion#/ ClarionSharp / Clarion.NET.
Utilizing the advanced 4GL capabilities of Clarion's so-called "AppGen" (or "Application Generator"), the idea is to generate code based on .NET, producing not "native" Clarion code, but "Clarion#" code.
So that applications will be able to tap into the thousands of existing (and rapidly expanding) .NET functions and capabilities.
Clarion produces "Clarion" code. When viewed in an editor, the differences between Clarion ".NET" code and standard (for example, C#) code are so meaningless that one has to ask: "Why?" Clarion's .NET offerings are currently (and probably will be [my opinion]) behind any release of a .NET Framework by Microsoft -- for the mere fact that the Clarion language seems to trying to evolve, in the .NET environment, to "mimic" that of C#, or any other .NET language for that matter.
Clarion, by virtue of this, will it seems always be playing "catch-up" with the .NET Frameworks. At the release of .NET 4.0 for example, Clarion# supported .NET 2
Until Clarion generates not a "Clarion Derivative" of C#, for example, but pure C#, it will always be in "catch-up" mode. An no developer capable of (for example, at the time of this writing) wanting to make use of the new Ms-Chart (Tm) capabilities in .NET 4.5 will be able to tap into them -- by using Clarion# alone. To do that, they would need to revert to using "COM-Interoperability", and use native WIN32 applications to interact with the latest .NET compilers.
This belief that Clarion will ever be able to match the latest .NET compilers makes Clarion#, ClarionSharp, Clarion.NET a decidedly "second choice" for Clarion developers wanting to venture into the .NET world. As expressed in the (paid for) forums; In order to take advantage of the latest .NET capabilities, there is simply no option but to not choose Clarion#, due to the technological "catch-up" gap.
Clarion is very similar to current mainstream languages, in that it does require every code block to be contained in a begin-end block, except for Routine declarations which automatically terminate on the next declaration of one. So this, for example is required:
If A# = 5 then J# = A# * 3 end
or, as Clarion allows, the use of the "end", you can use the period "." character in place of the "end" keyword, as in the example below:
If A# = 5 then J# = A# * 3 . ! < --- Note this period. It is the equivalent of an "end".
You can drop the "then" keyword, so it now becomes...
If A# = 5 J# = A# * 3 . ! < --- Note this period. It is the equivalent of an "end".
Or place it one one line (DO NOT FORGET THE PERIOD! This a common error and can cause endless compiler-error problems...)
If A# = 5 then J# = A# * 3. ! NOTE -- the "." at the end of the line is the equivalent of an "end".
Use of Templates
Clarion generates its code by means of templates. Tried and tested over many years, rock-solid base code is produced as a result. Although the templates are editable, the template generated code is not. So this leaves Clarion Developers with the option of (a) modifying the templates (by means of a fully-documented Template Language Reference), or (b) Creating templates that produce code that is exactly as they want it to produce the code it generates.
Wide Variety of 3rd Party Extensions / Inter-Language Support
A number of 3rd Party Vendors, most notably "CapeSoft", based in South Africa, (http://www.capesoft.com), produces a wide variety of advanced "add-ins", that extend the capabilities of Clarion. It must be noted however, that most 3rd Party Vendors do "wrap" other language capabilities into their products, which is something that any Clarion Developer familiar with any of these other languages is quite capable of doing themselves.
An example of the combining the capabilities of Clarion with other languages and platforms, thereby extending Clarion's native capabilities can be found at http://www.chilkat.com , which has library offerings allowing for integration of Clarion projects with the following languages/platforms, which Clarion is easily able to integrate into any of its products:
Android™ Classic ASP C C++ C# Delphi ActiveX Delphi DLL Visual FoxPro Java MFC Objective-C Perl PHP ActiveX PHP Extension PowerShell Python Ruby SQL Server Unicode C Unicode C++ Visual Basic 6.0 VB.NET VBScript
Clarion is data-centric, meaning it is designed to be used among a wide variety of database vendors, and is focused around the data. This means a table which is targeted at for example a .TPS file can be fairly easily ported to a Microsoft-SQL table, by simply choosing the new database target (MSSQL), and providing the required Ms-SQL database accessibility criteria (eg. ServerName, DatabaseName, UserName, Password).
This is on of Clarion's most powerful capabilities -- the code it produces supports any of the database drivers it ships with -- most times without the need for code changes at all. The language "translates" into the relevant language required for the database transparently, allowing the Clarion Developer to not have to deal with low level issues.
Clarion natively supports the following database formats, including, but not limited to:
ASCII Basic BTrieve Clarion (.DAT) TopSpeed (.TPS) Clipper DBaseIII DBaseIV DOS FoxPro/FoxBase Ms-SQL (T-SQL) ODBC (here you can go DB/2 or any other database that supports ODBC -- so in reality, ANY database format that has an ODBC driver available for it) Pervasive SQL SQLLite MySQL Oracle
In addition, due to its ability to readily interact with any .NET Class Library, it is able to leverage off of any of the very latest technologies from a database perspective, including ASP.NET and any others that Microsoft makes available. Including Windows Communication Foundation, Windows Communication Foundation, and Windows Workflow Foundation. Of any version.
Clarion is a language that is very easy to learn. The "Learning Clarion" PDF can be read in a day or two. However, in order to begin programming in clarion, you must purchase the Clarion compiler/development platform, which has an entry level cost of over $1000.
Clarion supports strongly typed data types, implicit variables, and also "variants" (that is, data of any type that are interpreted by the compiler, and the required data conversions done automatically). Some Examples:
I# = 0
J# = 5
K# = 10
I# = J# + K#
Here, I# (which is a 32 bit integer), would equal 15.
Variants: "Mixed data types taken care of by the compiler"
So if you declared "MichaelsAge" as a STRING, it would be quite legal to write:
A# = 10
MichaelsAge = 'The age of Michael is ' & A#
Which would give the value of the STRING variable MichaelsAge as: "The age of Michael is 10"
In all of the areas of the "data dictionary data declaration sections", namely the "global data section", the "module-specific data declaration section", and the "local data data declaration sections", when you declare a (simple or complex data type or variable), you can also declare it's "prompt, or label", "mask", or "picture", whether it is read-only on not, to be skipped on the form or not, the foreground and background color, transparency, and a whole host of other attributes.
So that if you ever drop that variable on a form in Clarion's IDE (Designer), it adopts those properties automatically, and they are reflected automatically. In other words, the data dictionary (or 'database' in SQL terms), contains not only information about the data itself, but also information about how it should be represented in applications which make use of the "database" declaration itself.
Therefore, the more time a Clarion Developer spends time defining the data-dictionary, the more time they will save later on when the 4GL application generator produces output, typically lists of data with full CRUD capabilities, validation, automatic lookup from "child" table capabilities etc.
A demonstration of a Hello World program in Clarion.
PROGRAM CODE MESSAGE('Hello World!','Clarion') RETURN
Programing for Non-Programmers
The sample code shown in the "Hello World" example is an example of "hand-written" code, which the Clarion compiler will gladly compile.
Because Clarion, as a 4GL language, is template-based, and the code the templates produce are consistent and have been refined over decades. This allows programmers who choose to use clarion, to quickly throw together prebuilt application modules built by other developers.
The Global Map
One of the things Clarion includes is what is called "Global Map".
Inside here, procedure definitions are declared, including, if required, declarations to external DLL's or Libraries written in non-Clarion languages. For use by the Clarion application. Clarion also has the ability to generate DLL's that can be consumed by external non-Clarion applications, taking full advantage of all of Clarion's 4GL capabilities and simply "plugging in" to the procedures it has created.
Within this MAP, it is able to leverage of all of the Windows-API declarations, using, if required, the no-longer documented data types that are core to the Windows O/S. Easily.
Interop with .NET Libraries
Thanks to support from the developer community, Clarion is able to access some of the current .NET functionality. Unmanaged Exports, a nuget package developed by Robert Gieseck (https://www.nuget.org/packages/UnmanagedExports), allows you expose functions developed in a .NET library to native languages on Windows. This is helpful for those who are forced to maintain a Clarion product but have no way of upgrading third party tools due to lack of support. Most of the third party tools can be rewritten in .NET with ease.
- "Health Care Services Leader McKesson’s History | Our History". McKesson. Retrieved 2012-03-14.
- Topspeed and Wise Solutions Form Business Alliance[dead link]
- Modeling Data and Designing Databases
- Topspeed Ships Clarion Internet Edition[dead link]
- Clarion Versions
- InformationWeek Clarion Cuts Down On Coding
- SoftVelocity Official Development Blog
- SoftVelocity Official Web Forums Archived 12 May 2008 at the Wayback Machine
- Online Magazine for Clarion software development
- ClarionLive! Weekly Clarion Webinar held by Clarion Developers
- SetupBuilder Installation System for Clarion software developers
- Thin@ Thin Client for developing SaaS Business Internet Applications with Clarion
- Comp.Lang.Clarion UseNet Group
- Clarion Integrator .Net