Planet Object Pascal

November 24, 2014

Te Waka o Pascal

Visual Studio Pro for just $0 !!!

Not exactly hot off the presses but some people apparently seem still to be unaware that my suggestion for a Community Edition of Delphi has been picked up (some years later, mind you). Except that it isn’t Embarcadero that have picked it up, but Microsoft. The Deal Just Got Better Some might recall that a […]

by Jolyon Direnko-Smith at November 24, 2014 07:45 AM

November 21, 2014

Firebird News

Conference Report Firebird 2014 and presentations

On October 24-25, 2014 in Prague, we hosted an international conference of Firebird. Attended by 110 participants, 18 speakers presented 23 interesting presentations. The conference was open with core developers of Firebird Dmitry Emanov and Vlad Khorsun, with reports about new features of Firebird 3, which is preparing to release in early 2015, and Firebird […]

by mariuz at November 21, 2014 09:24 AM

November 20, 2014

The Wiert Corner - irregular stream of stuff


Please someone add the Software on a String blog to DelphiFeeds (:

Great article on testing implementations of interfaces in a generic way. With examples in NUnit and DUnit.

How do I test an interface? Should I even do that? | Software on a String.

And then Stefan Glienke made a great comment at making the DUnit implementation even easier:

But even if you go without that extra base class the cool thing is that you don’t need to restrict your classes to be a TInterfacedObject but specify the interface they need to implement (yay, compiletime type safety) and then you can get rid of the Supports call and directly assign the result of the ctor call to the sut variable.


Stefan’s code:

Filed under: Delphi, Delphi 2007, Delphi 2010, Delphi XE, Delphi XE2, Delphi XE3, Delphi XE4, Delphi XE5, Delphi XE6, Delphi XE7, Development, Software Development

by jpluimers at November 20, 2014 11:00 AM


Ever since the Delphi build engine got changed to MS Build in Delphi 2007, many people use Delphi build events. Their order is prebuild, prelink and postbuild (or maybe better spelled pre-build, pre-link and post-build).

Before Delphi 2007, you had to fiddler with project groups and dependencies to fake pre-build and post-build events. For an example see Pre and Post-Build Automation in Delphi.

One of the really good things about these events is that build events appear in the output tab of the messages window.

One of the really bad things is that there is hardly any documentation about the build events.

At least two important things are missing:

  1. How the lines of a build event are actually executed
  2. How parameter expansion works inside build events

Let’s explain these.

Executing the source lines of a build event.

I can cut this short very easily: build events are not batch files.

What happens is that all lines in your build event are concatenated together using ampersand (&) signs which are used to execute multiple commands on one command line.

This means that all the fancy control structures (if statements, setlocal, for loops) are not possible inside build events.

The alternative is to call a batch file from a build event, and have your control structures there.

But for that, you have to pass parameters, which leads to the expansion of $() parameters:

Expansion of the $() parameters inside build events

I could not find any official documentation of the $() parameters on the Embarcadero sites.

Ken White took the effort to type the parameters from Delphi 2010 into a StackOverflow answer (that list is gone in Delphi XE, but the bug reports on that got fixed in Delphi XE2 and up), and since then they have not changed:

BDS                 The environment variable $(BDS)
DEFINES             The project's conditional defines
DIR                 The environment variable $(DIR)
INCLUDEPATH         The project's include path
INPUTDIR            The input file's directory
INPUTEXT            The input file's extension
INPUTFILENAME       The input file's name, with extension
INPUTPATH           The input file's full path
LOCALCOMMAND        Local command entered by user in project manager
OUTPUTDIR           The output file's directory
OUTPUTEXT           The output file's extension
OUTPUTFILENAME      The output file's name, with extension
OUTPUTNAME          The output file's name, without extension
OUTPUTPATH          The output file's full path
Path                The environment variable $(PATH)
PROJECTDIR          The project's directory
PROJECTEXT          The project's extension
PROJECTFILENAME     The project file's name, with extension
PROJECTNAME         The project's name
PROJECTPATH         The project file's full path
SAVE                Save the input file to disk before it's compiled
SystemRoot          The environment variable $(SYSTEMROOT)
WINDIR              The environment variable $(WINDIR)

A nice list, but it doesn’t tell you what the values are (apart from the environment variables). So I compared the output of build-events like this:

>> %temp%\pre-build.txt echo BDS: $(BDS)
>> %temp%\pre-build.txt echo Config: $(Config)
>> %temp%\pre-build.txt echo DEFINES: $(DEFINES)
>> %temp%\pre-build.txt echo DIR: $(DIR)
>> %temp%\pre-build.txt echo INCLUDEPATH: $(INCLUDEPATH)
>> %temp%\pre-build.txt echo INPUTDIR: $(INPUTDIR)
>> %temp%\pre-build.txt echo INPUTEXT: $(INPUTEXT)
>> %temp%\pre-build.txt echo INPUTFILENAME: $(INPUTFILENAME)
>> %temp%\pre-build.txt echo INPUTNAME: $(INPUTNAME)
>> %temp%\pre-build.txt echo INPUTPATH: $(INPUTPATH)
>> %temp%\pre-build.txt echo LOCALCOMMAND: $(LOCALCOMMAND)
>> %temp%\pre-build.txt echo OUTPUTDIR: $(OUTPUTDIR)
>> %temp%\pre-build.txt echo OUTPUTEXT: $(OUTPUTEXT)
>> %temp%\pre-build.txt echo OUTPUTFILENAME: $(OUTPUTFILENAME)
>> %temp%\pre-build.txt echo OUTPUTNAME: $(OUTPUTNAME)
>> %temp%\pre-build.txt echo OUTPUTPATH: $(OUTPUTPATH)
>> %temp%\pre-build.txt echo Path: $(Path)
>> %temp%\pre-build.txt echo Platform: $(Platform)
>> %temp%\pre-build.txt echo PROJECTDIR: $(PROJECTDIR)
>> %temp%\pre-build.txt echo PROJECTEXT: $(PROJECTEXT)
>> %temp%\pre-build.txt echo PROJECTFILENAME: $(PROJECTFILENAME)
>> %temp%\pre-build.txt echo PROJECTNAME: $(PROJECTNAME)
>> %temp%\pre-build.txt echo PROJECTPATH: $(PROJECTPATH)
>> %temp%\pre-build.txt echo SAVE: $(SAVE)
>> %temp%\pre-build.txt echo SystemRoot: $(SystemRoot)
>> %temp%\pre-build.txt echo WINDIR: $(WINDIR)
"$(INPUTDIR)Copy_FastMM_FullDebugMode_Dll_PostBuildEvent.bat" "$(Platform)" "$(INPUTDIR)..\..\..\..\..\\FullDebugMode DLL\Precompiled\" "$(OUTPUTDIR)"

I ran it using the project C:\Users\Developer\SVN\\Native\Delphi\Apps\Copy_FastMM_FullDebugMode_Dll_PostBuildEvent\Copy_FastMM_FullDebugMode_Dll_PostBuildEvent.dproj

The objective was to copy the correct FastMM FullDebugMode DLL into the directory of the .EXE (more on that later).

Observations of the events:

  • pre-link is not executed
  • pre-build and post-build get executed
  • pre-build and post-build give the same output

Output of pre-build.txt converted to a html table (too bad you cannot have code or pre tags around a table tag):

BDS c:\program files (x86)\embarcadero\rad studio\11.0
Config Debug
INCLUDEPATH c:\program files (x86)\embarcadero\rad studio\11.0\lib\Win64\release;C:\Users\Developer\Documents\RAD Studio\11.0\Imports;c:\program files (x86)\embarcadero\rad studio\11.0\Imports;C:\Users\Public\Documents\RAD Studio\11.0\Dcp\Win64;c:\program files (x86)\embarcadero\rad studio\11.0\include;C:\Program Files (x86)\FastReports\LibD18x64;C:\Program Files (x86)\Raize\CS5\Lib\RS-XE4\Win64
INPUTDIR C:\Users\Developer\SVN\\Native\Delphi\Apps\Copy_FastMM_FullDebugMode_Dll_PostBuildEvent\
INPUTFILENAME Copy_FastMM_FullDebugMode_Dll_PostBuildEvent.dproj
INPUTNAME Copy_FastMM_FullDebugMode_Dll_PostBuildEvent
INPUTPATH C:\Users\Developer\SVN\\Native\Delphi\Apps\Copy_FastMM_FullDebugMode_Dll_PostBuildEvent\Copy_FastMM_FullDebugMode_Dll_PostBuildEvent.dproj
OUTPUTDIR C:\Users\Developer\SVN\\Native\Delphi\Apps\Copy_FastMM_FullDebugMode_Dll_PostBuildEvent\Win64\Debug\
OUTPUTFILENAME Copy_FastMM_FullDebugMode_Dll_PostBuildEvent.exe
OUTPUTNAME Copy_FastMM_FullDebugMode_Dll_PostBuildEvent
OUTPUTPATH C:\Users\Developer\SVN\\Native\Delphi\Apps\Copy_FastMM_FullDebugMode_Dll_PostBuildEvent\Win64\Debug\Copy_FastMM_FullDebugMode_Dll_PostBuildEvent.exe
Path C:\Users\Public\Documents\InterBase\redist\InterBaseXE3\win32_togo;C:\Users\Public\Documents\InterBase\redist\InterBaseXE3\win64_togo;C:\Program Files (x86)\Embarcadero\RAD Studio\11.0\Redist\boost\win64;C:\Program Files (x86)\Embarcadero\RAD Studio\11.0\Redist\boost\win32;C:\Program Files (x86)\CollabNet;C:\Program Files (x86)\Embarcadero\RAD Studio\11.0\bin;C:\Users\Public\Documents\RAD Studio\11.0\Bpl;C:\Program Files (x86)\Embarcadero\RAD Studio\11.0\bin64;C:\Users\Public\Documents\RAD Studio\11.0\Bpl\Win64;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\Microsoft\Web Platform Installer\;C:\Program Files (x86)\Microsoft ASP.NET\ASP.NET Web Pages\v1.0\;C:\Program Files (x86)\Windows Kits\8.0\Windows Performance Toolkit\;C:\Program Files\Microsoft SQL Server\110\Tools\Binn\;C:\Program Files\TortoiseSVN\bin;C:\Program Files\TortoiseHg\;C:\BIN
Platform Win64
PROJECTDIR C:\Users\Developer\SVN\\Native\Delphi\Apps\Copy_FastMM_FullDebugMode_Dll_PostBuildEvent
PROJECTFILENAME Copy_FastMM_FullDebugMode_Dll_PostBuildEvent.dproj
PROJECTNAME Copy_FastMM_FullDebugMode_Dll_PostBuildEvent
PROJECTPATH C:\Users\Developer\SVN\\Native\Delphi\Apps\Copy_FastMM_FullDebugMode_Dll_PostBuildEvent\Copy_FastMM_FullDebugMode_Dll_PostBuildEvent.dproj
SystemRoot C:\Windows
WINDIR C:\Windows

Observations of the values

Partially lowercase:

  • INCLUDEPATH: c:\program files (x86)\embarcadero\rad studio\11.0\lib\Win64\release;C:\Users\Developer\Documents\RAD Studio\11.0\Imports;c:\program files (x86)\embarcadero\rad studio\11.0\Imports;C:\Users\Public\Documents\RAD Studio\11.0\Dcp\Win64;c:\program files (x86)\embarcadero\rad studio\11.0\include;C:\Program Files (x86)\FastReports\LibD18x64;C:\Program Files (x86)\Raize\CS5\Lib\RS-XE4\Win64


  • BDS: c:\program files (x86)\embarcadero\rad studio\11.0
  • INPUTEXT: .dproj
  • OUTPUTEXT: .exe
  • PROJECTEXT: .dproj


  • DIR:
  • SAVE:

Ends with backslash:

  • INPUTDIR: C:\Users\Developer\SVN\\Native\Delphi\Apps\Copy_FastMM_FullDebugMode_Dll_PostBuildEvent\
  • OUTPUTDIR: C:\Users\Developer\SVN\\Native\Delphi\Apps\Copy_FastMM_FullDebugMode_Dll_PostBuildEvent\Win64\Debug\

No backslash:

  • PROJECTDIR: C:\Users\Developer\SVN\\Native\Delphi\Apps\Copy_FastMM_FullDebugMode_Dll_PostBuildEvent

I tried these Intel based platforms in Delphi XE4:

  • Platform: OSX32
  • Platform: Win32
  • Platform: Win64

So that’s where the Copy_FastMM_FullDebugMode_Dll_PostBuildEvent came in (:

Future research

I need to put some more research into where these values are filled, and how you can pass your own to the MSBUILD process.

According to name, with extension INPUTPATH The input file’s full path LOCALCOMMAND Local command entered by user in project manager OUTPUTDIR The output file’s directory OUTPUTEXT – CodeInPro
and What are the MSBuild project level properties for Delphi? – Stack Overflow,
many values are set in
but that has since then moved to files named like this:
C:\Program Files (x86)\Embarcadero|CodeGear\RAD Studio\*.0\bin\CodeGear.*.Targets

Nobody seems to know about $(LOCALCOMMAND): Article 10854 Subject D2010 Build Events – Use of $(LOCALCOMMAND)? Where does it come from? on embarcadero.public.delphi.ide.


Filed under: Delphi, Delphi 2005, Delphi 2006, Delphi 2007, Delphi 2009, Delphi 2010, Delphi XE, Delphi XE2, Delphi XE3, Delphi XE4, Delphi XE5, Development, FastMM, Software Development

by jpluimers at November 20, 2014 05:00 AM

November 19, 2014

Firebird News

Firebird Foundation members are eligible for discounts

The Firebird Foundation (FF) is the organization behind Firebird that actually pays for the salaries of the core developers. FF gets its money from associations, donations and sponsorship. Anyone can become a member of the FF (USD 50/year for non voting member, and USD 300/year for voting member) and every member of the FF are eligible for special […]

by Cantu at November 19, 2014 01:25 PM

100 Open Source replacements for expensive software

Firebird is listed in the “100 Open Source Replacements for Expensive Applications” article: 31. Firebird Replaces Microsoft SQL Server Standard ($899 and up) Under development for more than three decades, Firebird is a relational database that boasts “excellent concurrency, high performance, and powerful language support for stored procedures and triggers.” Paid support is available through […]

by Cantu at November 19, 2014 12:08 PM

Did you purchased XE Plus Pack?

If you previously purchased XE Plus Pack and have moved onto Delphi XE2 or above, please contact me for you free upgrade license details.


XE Plus Pack ONLY works with Delphi XE.

The XE2 Plus Pack and above (the name changes for the supported IDE) is not free.

I have no plans to make it free. However, a license purchased for XE2 Plus Pack (or above) will work with any Embarcadero released IDE from Delphi XE2. So the same key will work with XE3, XE4, XE5, XE6, XE7 (see below) and even XE8 if that is what the next release will be called…

XE7 Plus Pack

The Delphi XE7 Plus Pack is currently in beta and was held back due to Update 1. It should be available to trial in a week or so.

Existing users can contact me for access to the beta.


by JED at November 19, 2014 07:14 AM

The Wiert Corner - irregular stream of stuff


A while ago I bumped into a funny problem with Delphi XE.

I moved all the code from the .dpr in a Main unit (the IDE sometimes overwrites part of the DPR).

This normally isn’t a problem, until Delphi re-generates the .RES file. The reason is that this .RES file can contain a manifest which enables Windows theming.

If there is no reference of the Application object in the .DPR, the IDE will remove the Theming manifest from the .RES file, so your application run unthemed.

Three solutions:

  • include a reference to the Application in the .dpr,
  • or add the XPMan unit to the uses list  (no need to put the TXPManifest on a form or datamodule),
  • or upgrade to Delphi XE2 or newer.

You don’t see the effect until the IDE does regenerate the RES file. Which it will do when you change the version information. Which you had to do for the new build.
Took some effort to find the actual steps that overwrote the RES. It’s kind of undocumented.

Note: this happens at least in Delphi XE, and probably in Delphi 2005-2009 as well.

It was fixed in Delphi XE2, where you can even choose your own .manifest file which is great, because besides theming, you can also control UAC through the manifest.

Note: if you want an UAC manifest, you

  1. have to create your own manifest containing the requestedPrivileges and requestedExecutionLevel nodes.
  2. merge it with any theming manifest
  3. make sure you don’t have another theming manifest included (remove all XPMan references from your code, don’t use the Themed manifest in the project options).

From Delphi XE2 and up, just reference the manifest file from the project options. For XE and below, create an RC file referencing the manifest, compile the RC into a RES and include the RES in your application.


Filed under: Delphi, Delphi XE, Delphi XE2, Delphi XE3, Delphi XE4, Delphi XE5, Development, Software Development

by jpluimers at November 19, 2014 05:00 AM

The Podcast at

What is the Internet of Things?

You’ve no doubt seen talk of the Internet of Things, or the Internet of Everything even, but you may still wonder what it is. Well, it isn’t a product or a feature you will buy, it has more in common with the “information age” or “industrial revolution” then “smart phone” or even the Internet itself.

It took me a while to warm up to the idea. At first I thought it was just marketing hype, but now I am really excited and see it as part of a huge trend that is going to really change life as we know it. In fact we’ve already seen a lot of the changes. The Internet of Things (IoT) isn’t something coming someday; it is something already here and is only going to get bigger.

Gartner's 2014 Hype Cycle of Emergine Technologies

Gartner says we are 5 to 10 years away from seeing the full productivity of IoT


The basic idea is that all sorts of “ordinary things” get connected to the Internet, but I believe that really misses the point. IoT is really the combination of four technologies: The cloud, computer miniaturization & commoditization, smart devices, and ubiquitous connectivity. I’d say ubiquity is a theme of IoT. These four technologies have been gaining steam individually, but as they come together we see massive changes.

Over the next few blog posts we can discuss each technology individually, and then we can discuss what they mean together. I’d love to hear your feedback along the way.

Did you know RAD Studio XE7 is great for building apps that connect with the Internet of Things? I’ll discuss that more in some of my future posts, but right now there are a lot of great special offers that make upgrading to XE7 a no brainer. I’d feel bad if you missed these special offers because you were waiting for me to get to the point. If you just download and activate the trial by Nov 21st you get a free copy of Nick’s book.

by Jim McKeeth at November 19, 2014 12:17 AM

November 18, 2014

The Wiert Corner - irregular stream of stuff


This should not be difficult to do, just time consuming. So it is on my research list to see how time consuming: build a TXMLDocument binding for OmniXML.

This is to urge less people to try to parse XML by hand like xml – Copy & Copy does not work correctly with stringlist – Stack Overflow.


via: Delphi, OmniXML – XML binding? – Stack Overflow.

Filed under: Delphi, Delphi XE4, Delphi XE5, Development, Software Development, XML/XSD

by jpluimers at November 18, 2014 05:00 AM

November 17, 2014

Delphi Bistro

Delphi Jobs available in Alabama, NY, Paris and Seattle

If  you want to come work for the coolest company that writes software using your favorite language, then now is the time to send me  your resume! Email it to afletcher at wideorbit dot com.

If you have a lot of Delphi experience, as well as SQL experience, send me your resume (afletcher at wideorbit dot com). You owe it to yourself to take a chance at working for a great company that has a team of great people that love Delphi as much as you do!

C’mon, you owe it to yourself,  take the first step and Send me your resume (afletcher at wideorbit dot com) and I’ll personally deliver it to the right person.

Positions are open in Lynnwood, WA (Seattle area), Birmingham (AL), New York (NY) and Paris (France).

You must be able to work in the US  for he American positions and the EU for the French position.

by Fletch at November 17, 2014 09:21 PM

November 16, 2014

Castle Game Engine news

New exciting Spine improvements in our Castle Game Engine! Spine allows to create great 2D game animations...

New exciting Spine improvements in our Castle Game Engine!

Spine allows to create great 2D game animations, that can be used within our engine. For example uses Spine with our engne :) New wiki page documents Spine support in the Castle Game Engine.

Recently implemented Spine features:

1. Slot color and transparency can be animated.

2. Slot draw order can be animated (by "draw order timeline").

3. Using Spine model without an atlas is possible. Expects images in images/<attachment-name>.png files. Note that without atlas, we lose some speed (texture switching) and even quality (textures may be resized to power-of-2 on some GPUs; atlas avoids it by always creating an atlas page with power-of-2). So atlas is still advised, although it is not required anymore.

4. Start of skinnedmesh support. The skinnedmesh in setup pose is affected by bones correctly, and during animation it moves as a whole (is affected by parent bone transformation). Missing is the ability to recalculate vertexes affected by bones during animation (that is, to deform skinnedmesh during animation).

5. NavigationInfo.blendingSort X3D extension allows to force blending sort by VRML/X3D author to NONE, 2D, 3D. Spine models automatically include blendingSort=2D, so they just open Ok in view3dscene ( You may find useful to use blendingSort=3D for 3D scenes where there are many transparent 3D objects visible over each other.

November 16, 2014 01:29 AM

November 15, 2014

Firebird News

FDB Python driver for Firebird v1.4.3 is available for download.

This mostly bugfix version introduces a backward incompatible change to events API, so read the Release Notes before deployment.

by mariuz at November 15, 2014 09:08 AM

November 14, 2014

Firebird News

IBSurgeon FBMonLogger 1.5 is released

IBSurgeon is glad to announce the general availability of FBMonLogger 1.5. IBSurgeon FBMonLogger is a tool to analyse monitoring tables output in Firebird and find problems with slow SQL queries, wrongly designed transactions (long-running transactions, transactions with incorrect isolation level, etc) and identify problematic applications.  More details about FBMonLogger: FBMonLogger is included into IBSurgeon […]

by IBSurgeon News at November 14, 2014 06:56 PM

November 13, 2014

The Wiert Corner - irregular stream of stuff

Firebird News

IPv6 support support landed in Firebird 3.0 trunk

IPv6 support is now landed in firebird trunk , please test ipv6 support from Firebird 3.x snapshots for Linux and Windows. Thanks to Michal Kubecek for his contribution

by mariuz at November 13, 2014 06:54 AM

The Wiert Corner - irregular stream of stuff


A while ago, I wrote a via PowerShell script to show the component packages (BPL) files for all installed Delphi (actually: BDS) versions for a couple of reasons:

  • I was creating installation instructions for getting new development machines set-up
  • The new machines had to either have a minimum subset of installed Delphi versions  + components, or the maximum superset of all the existing development machines
  • Sifting through the installed Packages in the IDE, or registry by hand was cumbersome

Note that in the mean time (I queued this blog entry somewhere in 2013) the script has moved to BitBucket, I’ve written more scripts (like Dependencies.bat which is documented in and Run-Dependend-rsvars-From-Path.bat), all modified all scripts to support all BDS versions I had access to, and a write nice conference paper on Build Automation for Delphi that references the scripts.

Since none of the machines were using pre BDS installations, I could limit the script to BDS 1.0 and up.

The very first (1.0) version of BDS (also known as the Gailileo IDE foundation) was in fact not a Delphi version, but C# Builder 1.0. All Delphi versions since then are based on BDS. The script is based on the BDS registry keys I researched and wrote about in Files in your Delphi settings directory; How to relocate the Favourites on your Welcome page.

Since registry access can be very much flow based, the pipeline architecture of PowerShell is a good fit.

So I wrote a PowerShell script (:

Note Thomas Mueller has written a batch file around the same set of registry keys; the thread there also has some insight in the HKLM versus HKCU keys.

I will explain my script step by step, and start with the most important one: Set-StrictMode -Version Latest.

By default, PowerShell is very lenient. You’d think that is a good thing for PowerShell novices, but in practice it isn’t. It might be a good thing for PowerShell gurus (I’m far from that), but the default configuration makes PowerShell not complain until it really has no clue what you actually did wrong.

A few things that causes Set-StrictMode (you have to hack around to implement Get-StrictMode)  to stop with an error are at Powershell: Set-StrictMode -Version Latest.:

Set-StrictMode -Version Latest

PowerShell script best practices has some other tips on what you should add in the header of your scripts, and for legacy code: Set-StrictMode and legacy code issues.

Set-StrictMode -Version Latest

Main code at the end of your script

The functions in the file can be tested one-by-one in this block at the end of the file (you can only call functions declared earlier in the file), and indicate the versatility of this PowerShell file:


Registry paths, default parameters and error handling

Most functions have default parameter values, in these cases virtually everywhere the base registry path for BDS 8.0 (Delphi XE)

I know that you can specify Registry keys without quotes, but I’m accustomed using quotes in other languages, so I use quotes in PowerShell too.

One of the things that can happen is that you do not have all BDS editions installed on one machine, so one of the registry paths does not exist.

I’ve used -ErrorAction SilentlyContinue here to convert this potential error condition into a $null response which is handled by the if statement.
More detailed advice on such error handling can be found at Managing non-terminating errors – Windows PowerShell Blog – Site Home – MSDN Blogs.

Another thing you will see a lot in my script is hashes (#) in front of lines that I used for debugging purposes. A great feature of PowerShell is that anything you do not return, but produces something will be sent to the standard output. So removing the hashes below will reveal the content of $key and a table formatted $nameValues as text. Nice!

Note I use the “Known Packages” key, but skip the “Known IDE Packages” key. That is explained by Allen Bauer in Why my Delphi IDE Expert is not initialized when use the “Known IDE Packages” Key? – Stack Overflow and Mark Edington in his post Mark Edington’s Delphi Blog : Delphi Startup Times and the Kitchen Sink about Delphi personalities.

function Get-KnownPackages {
        [string]$basePath = 'hkcu:\Software\Embarcadero\BDS\8.0'
    $path = $basePath + '\Known Packages'
    $key = Get-Item $path -ErrorAction SilentlyContinue
    if ($key) {
        # $key
        $names = $key.GetValueNames()
        $namevalues = $names |
            ForEach-Object { [PSCustomObject]@{ Name = $_; Value = $key.GetValue($_) } }
        # $namevalues | Format-Table
    else {
        $namevalues = $null

Matching with Regular Expressions

Sifting through the packages, I wanted to know which ones were system installed (by the Delphi installer), and user installed. My empiric observation was that all packages installed into directories starting with $(BDS) or $(BDSLIB).

Since searching with -match or -notMatch involves regular expressions, the dollar and parenthesis need to be escaped, so you end up with \$(BDS) or \$(BDSLIB).

function Filter-BDS-Packages {
        [string]$basePath = 'hkcu:\Software\Embarcadero\BDS\8.0',
        [boolean]$excludeMatch = $True
    $namevalues = Get-KnownPackages($basePath)

    if ($nameValues) {
        $bdsBinAtStart = '^\$\(BDSBIN\)'
        $bdsAtStart = '^\$\(BDS\)'
        if ($excludeMatch) {
            $matches = $namevalues | Where-Object {
                $_.Name -notMatch $bdsBinAtStart -and `
                $_.Name -notMatch $bdsAtStart
        else {
            $matches = $namevalues | Where-Object {
                $_.Name -match $bdsBinAtStart -or `
                $_.Name -match $bdsAtStart
    else {
        $matches = $null

The next step is getting BDS Versions, product and company names. I’m following the lists from Files in your Delphi settings directory; How to relocate the Favourites on your Welcome page here.

First the singular versions of the functions.

Most of these use the PowerShell switch statement to map from BDS version to CompanyName.

function Get-BDS-CompanyName {
    param (
        $bdsVersion = 1
     CompanyName=Borland (from BDS 1 until BDS 5)
     CompanyName=CodeGear (from BDS 6 until BDS 7)
     CompanyName=Embarcadero (BDS 8 and up)
    $borland = 'Borland'
    $codeGear = 'CodeGear'
    $embarcadero = 'Embarcadero'
    switch ($bdsVersion) {
        1 { return $borland }
        2 { return $borland }
        3 { return $borland }
        4 { return $borland }
        5 { return $borland }
        6 { return $codeGear }
        7 { return $codeGear }
        Default { return $embarcadero }

function Get-BDS-ProductName {
    param (
        $bdsVersion = 1

    switch ($bdsVersion) {
        1       { 'C# Builder' }
        Default { 'Delphi' }

function Get-BDS-ProductVersion {
    param (
        $bdsVersion = 1

    switch ($bdsVersion) {
        1 { '1' }
        2 { '8' }
        3 { '2005' }
        4 { '2006' }
        5 { '2007' }
        6 { '2009' }
        7 { '2010' }
        8 { 'XE' }
        9 { 'XE2' }
        10 { 'XE3' }
        11 { 'XE4' }
        12 { 'XE5' }

and some of them use string formatting using the -f format operator:

function Get-BDS-BaseKeyPath {
    param (
        $bdsVersion = 1,
        $rootKey = 'hkcu'
    $company = Get-BDS-CompanyName $bdsVersion
    $pathFormat = '{0}:\Software\{1}\BDS\{2}.0'
    # 'hkcu:\Software\Embarcadero\BDS\8.0' $True
    $path = $pathFormat -f $rootKey, $company, $bdsVersion

function Get-BDS-ProductFullName {
    param (
        $bdsVersion = 1
     1. Borland C# Builder (contained only C# Builder)
     2. Borland Delphi 8 (added Delphi .net)
     3. Borland Delphi 2005 (added Delphi win32)
     4. Borland Delphi 2006 (added C++ Builder)
     5. Borland Delphi 2007
     6. CodeGear Delphi 2009 (Unicode; not a platform, but still)
     7. CodeGear Delphi 2010 (Generics done well)
     8. Embarcadero Delphi XE
     9. Embarcadero Delphi XE2 (added Delphi win64)
     10. Embarcadero Delphi XE3 (added C++ Builder win64, OS X x86 and iOS x86/arm through FreePascal)
     11. Embarcadero Delphi XE4 (replaced FreePascal with native Delphi compiler for iOS x86/arm)
     12. Embarcadero Delphi XE5 (added Android ARMv7)
    $company = Get-BDS-CompanyName $bdsVersion
    $name = Get-BDS-ProductName $bdsVersion
    $version = Get-BDS-ProductVersion $bdsVersion
    $fullNameFormat = '{0} {1} {2}'
    $fullName = $fullNameFormat -f $company, $name, $version

some are really simple calls to other methods (note that parameters in PowerShell are space separated, not comma separated):

function Get-BDS-HKCU-BaseKeyPath {
    param (
        $bdsVersion = 1
    $path = Get-BDS-BaseKeyPath $bdsVersion

function Get-BDS-HKLM-BaseKeyPath {
    param (
        $bdsVersion = 1
    $path = Get-BDS-BaseKeyPath $bdsVersion 'hklm'

The plural versions of the methods just call the singular versions, except for Get-BDS-Versions which initializes an array.

For arrays, I prefer strong typing. Instead of using @() to initialize an empty untyped array, I use [int[]] for a strongly typed array.

<pre>function Get-BDS-CompanyNames {
    $versions = Get-BDS-Versions
    $versions | ForEach-Object { Get-BDS-CompanyName $_ }

function Get-BDS-Versions {
    ## array initialization:
    [int[]] $versions = 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12

function Get-BDS-ProductNames {
  $versions = Get-BDS-Versions
  $versions | ForEach-Object { Get-BDS-ProductName $_ }

function Get-BDS-ProductVersions {
    $versions = Get-BDS-Versions
    $versions | ForEach-Object { Get-BDS-ProductVersion $_ }

function Get-BDS-ProductFullNames {
    $fullNames = Get-BDS-FullNames
    $fullNames | ForEach-Object { Get-BDS-ProductFullName $_ }

function Get-BDS-BaseKeyPaths {
    param (
        $rootKey = 'hkcu'
    $bdsVersions = Get-BDS-Versions
    $bdsVersions | ForEach-Object {
        $path = Get-BDS-BaseKeyPath $_ $rootKey

function Get-BDS-HKCU-BaseKeyPaths {
    $bdsVersions = Get-BDS-Versions
    $bdsVersions | ForEach-Object {
        $path = Get-BDS-HKCU-BaseKeyPath $_

function Get-BDS-HKLM-BaseKeyPaths {
    $bdsVersions = Get-BDS-Versions
    $bdsVersions | ForEach-Object {
        $path = Get-BDS-HKLM-BaseKeyPath $_

Finally, there is the Filter-BDS-Packages-For-All-Versions function which brings everything together.

It loops over user/system installed packages (parsing the PowerShell $True and $False boolean constants (though there are other ways to specify TRUE and FALSE in PowerShell).

The cool thing about arrays is that you can push them through pipes with ForEach-Object instead of classic for or do loops.

Every once in a while, you get this error when formatting output in PowerShell:

Object of type “Microsoft.PowerShell.Commands.Internal.Format.FormatStartData” is not valid or not in the correct sequence. This is likely caused by a user-specified “format-table” command which is conflicting with the default formatting.

It hardly occurs, but the trick solving only the symptom is to perform a pipe through Out-String to force the output into a series of strings. If anyone knows about the actual cause, please let me know. Especially if you also know how to resolve (:

Boolean not is either the ! or the -not operator. But since all other PowerShell logical operators start with a minus sign, I used -not for consistency.

There is also some $state debugging code left behind the # comment markers. Uncomment these when you want to trace through the code.

Finally a small trick: $anyInstalledPackages is used to mark if any packages have been found at all. If you have no Delphi or no packages installed, it will stay $False, and an appropriate message will be shown.

function Filter-BDS-Packages-For-All-Versions {
    $anyInstalledPackages = $False
    [bool[]]$filters = $True, $False
    $filters | ForEach-Object {
        $filter = $_
        $versions = Get-BDS-Versions
        $versions | ForEach-Object {
            $version = $_
            $basePath = Get-BDS-HKCU-BaseKeyPath $version
            # $state = [PSCustomObject]@{ Version = $version; Filter = $filter; Path = $basePath }
            # $state
            $userPacakgesNameValues = Filter-BDS-Packages $basePath $filter
            if ($userPacakgesNameValues) {
                $productFullName = Get-BDS-ProductFullName $version
                switch ($filter) {
                  $False  { $kind = 'System' }
                  Default { $kind = 'User' }
                $line = '{0} installed packages for "{1}" in {2}' -f $kind, $productFullName, $basePath
                Write-Host $line
                $userPacakgesNameValues | Format-Table | Out-String
                $anyInstalledPackages = $True
    if (-not $anyInstalledPackages) {
        Write-Host 'No installed Delphi packages found'

<span style="font-size: 12px; line-height: 18px;">

Finally the test code again:


Have fun with it!


Filed under: CommandLine, Delphi, Delphi 2005, Delphi 2006, Delphi 2007, Delphi 2009, Delphi 2010, Delphi 8, Delphi x64, Delphi XE, Delphi XE2, Delphi XE3, Delphi XE4, Delphi XE5, Development, PowerShell, Software Development

by jpluimers at November 13, 2014 05:00 AM

November 12, 2014

Firebird News

Latest QA Tester/Developer’s Reports

You can read Developers reports from previous months (until September/October) Pavel Zotov, 2014-10 Philippe Makowski, 2014-10 Alexander Potapchenko, 2014-10 Alex Peshkov,2014-10 Jiri Cincura,2014-10 Other Core developer reports ps:I didn’t remember to be posted here on FirebirdNews . You can view also the presentation/reports from Firebird conference

by mariuz at November 12, 2014 04:05 PM

The Wiert Corner - irregular stream of stuff


One of the things with Delphi and version control systems is that you’d rather have as few binary files in version control as possible.

One of the binary files in virtually every Delphi project is the RES file.

By default, it contains version information, and the icon for the project.

The compiler supports RC files, it’s just the IDE that insists on RES.

So on my research list is how to move everything to RC, and limit the IDE dependency on the RES files.


via: How to store a large text in a Delphi component? – Stack Overflow.

Filed under: Delphi, Delphi XE2, Delphi XE3, Delphi XE4, Delphi XE5, Development, Software Development

by jpluimers at November 12, 2014 05:00 AM

November 11, 2014

The Wiert Corner - irregular stream of stuff


One of the things a lot of Delphi users want is to be able to automagically remove unused units from their uses lists and projects.

The short answer is: you can’t.

The long answer starts with: you can’t fore a number of reasons.

Similar reasonings hold for many other development environments. Plain Windows EXEs and DLL dependencies. .NET projects and assembly dependencies, etc.

Initialization/Finalization dependency

The first reason is that each unit (module, assembly, or other dependency) can contain global code to be executed at unit start/load or finish/unload.

So even though you do not reference anything inside that unit, the initialization and finalization sections can be run.

Removing the dependency from your units and project, kills that functionality. And might break all sorts of things.

Load order dependency

Sometimes you have subtle load order dependencies of units. Those should be rare, and if they are there, should be enforced by the affected units themselves. But everyone knows those subtle dependencies are more often a by product not enforced by anything than coincidence.

So if you start removing references, the load order might change, and subtle bugs may occur.

In other words: test, test, test and test your codebase before and after removing unit references from uses lists.


If you understands the dependencies of initializtion/finalization or load order, you will get interested to know what units are actually being used.

The ultimate source for this would be the Delphi compiler. Bad luck here: you cannot use it as the IDE and command-line interfaces don’t offer a hook to it to do just this.

So you need alternative parsers that can help out. The answers to How to remove unused units from all source files on Delphi XE2 describe a few and they all have the same drawback: they are not the Delphi compiler, so they are a rough approximation of what the compiler would do.

And even if the approximation would be perfect, they all suffer from the same thing the compiler suffers from: you can only have one set of conditional defines, platforms, etc at the same time.

There is lots of code for which the usage is conditional, but where the uses list does not reflect this.


Optimizing uses lists to eliminate unused units seems a simple thing at start, but isn’t.

The best way to keep those optimized is to prune them while developing. So if you remove code, try to remember cutting down the uses lists by hand.

And then test, test, test and test your codebase.


via: ide – How to remove unused units from all source files on Delphi XE2? – Stack Overflow.

Filed under: Delphi, Delphi 1, Delphi 2, Delphi 2005, Delphi 2006, Delphi 2007, Delphi 2009, Delphi 2010, Delphi 3, Delphi 4, Delphi 5, Delphi 6, Delphi 7, Delphi 8, Delphi XE, Delphi XE2, Delphi XE3, Delphi XE4, Delphi XE5, Delphi XE6, Delphi XE7, Development, Software Development

by jpluimers at November 11, 2014 05:00 AM

November 10, 2014

Firebird News

Do you want Bitnami to add Firebird support?

Bitnami is a library of popular server applications and development environments that can be installed with one click, either in your laptop, in a virtual machine or hosted in the cloud. We take care of compiling and configuring the applications and all of their dependencies (third-party libraries, language runtimes, databases) so they work out-of-the-box. The […]

by Cantu at November 10, 2014 12:51 PM

twm’s blog

Setting a default language with dxgettext

By default, if no translation for a language is available, dxgettext will not do any translation but use the strings as they are in the source code. Sometimes this is not desirable. e.g.

  • Your customer does not understand the source language (e.g. your source language is not English but say German)
  • You are using dxgettext to convert special characters from a placeholder (e.g. “(R)” or “[deg]“) to the actual character (“®” or “°”)

In these cases you’d probably want the translation to default to a language that is actually supplied.

dxgettext doesn’t seem to have this feature (I looked quite hard) so I implemented it myself.

unit u_dzTranslator;


// ... other stuff ...

/// Sets the language to use </summary>
procedure UseLanguage(_LanguageCode: string);

/// gets a list of languages for which translations are available </summary>
procedure GetListOfLanguages(const _Domain: string; _Codes: TStrings;
  _Languages: TStrings = nil);

/// Sets the language to use if the desired language is not available,
/// defaults to English </summary>
procedure SetDefaultLanguage(const _LanguageCode: string);

// ... other stuff ...



// ... other stuff ...

  gblDefaultLanguage: string = DEFAULT_LANGUAGE;

procedure UseLanguage(_LanguageCode: string);
  Codes: TStringList;
  CurLang: string;
  i: Integer;
  p: Integer;

  CurLang := gnugettext.GetCurrentLanguage;
  Codes := TStringList.Create;
    GetListOfLanguages('default', Codes);
    for i := 0 to Codes.Count - 1 do begin
      if SameText(CurLang, Codes[i]) then begin
        // There is a translation for this language and country, everything is fine
        Exit; //-->
    // no translation found, try without the country code
    p := Pos('_', CurLang);
    if p 
 0 then begin
      CurLang := Copy(CurLang, 1, p - 1);
      for i := 0 to Codes.Count - 1 do begin
        if SameText(CurLang, Codes[i]) then begin
          // There is a translation for this language but not country, we can live with that
          Exit; //-->

  // we found no translation for this language, so we use the default language

procedure SetDefaultLanguage(const _LanguageCode: string);
  if _LanguageCode = '' then
    gblDefaultLanguage := DEFAULT_LANGUAGE
    gblDefaultLanguage := _LanguageCode;

procedure GetListOfLanguages(const _Domain: string; _Codes: TStrings; _Languages: TStrings = nil);
  i: Integer;
  gnugettext.DefaultInstance.GetListOfLanguages(_Domain, _Codes);
  if Assigned(_Languages) then begin
    for i := 0 to _Codes.Count - 1 do begin

// ... other stuff ...


Apart from the obvious, that is, setting a unit global variable to the desired default language, which itself defaults to English, this code changes the way UseLanguageWorks. It now does:

  • Call gnugettext.UseLanguage to let gnugettext do its stuff
  • Call gnugettext.GetCurrentLanguage to get the language that gnugettext uses (just in case gnugettext changes it from what was set with UseLanguage).
  • Gets a list of all supported translations
  • Tries to find a matching translation for the desired language and country.
  • If not found, tries to find a matching translation for the desired language, ignoring the country
  • If not found, changes the language to the default language.

Note that I just wrote this code, it might still contain bugs and is probably far from perfect. I will put it into the unit u_dzTranslator of my dzlib library and will fix any bugs I find in the future there.

by dummzeuch at November 10, 2014 11:16 AM

November 07, 2014

Žarko Gajić

Displaying Long Non-Breakable Text (File Path) In MessageDlg – Truncation/Ellipsis Issues

Introduced way back in Delphi 2009 the TTaskDialog (defined in Dialogs.pas) implements task dialogs. Task dialogs first appeared in Windows Vista and are used in later Windows versions. In essence, a task dialog is similar to, while much more flexible and parameter-rich than the standard message dialog. You’ve surely seen such fancy dialogs in action: those containing message title and text (content), icons, push buttons, radio buttons, expandable footer area and more.

In Delphi we have several options (including ShowMessage, MessageDlg, Application.MessageBox and some more) when it comes to displaying some modal message to the user. I’m rarely using ShowMessage and Application.MessageBox as both are not as flexible as MessageDlg (actually ShowMessage internally calls MessageDlg).

MessageDlg: Bruce Banner or Hulk ?

Using MessageDlg can result in 2 different displays of the actual message dialog. What will get displayed (and more importantly how) to the user is dependent on several factors including the following: Windows version your application is running on, if the application was built including runtime themes and if Windows uses themes.

If your application is running on Windows XP, MessageDlg internally creates and displays a standard Delphi form (though set to look and work as a dialog). If your application is running on at least Windows Vista (therefore Windows Vista, 7, 8, 10, etc) and runtime themes are enabled and used by Windows, MessageDlg will internally create the shiny task dialog! Actually, the TaskDialogIndirect API call will be made. Even though this beast of a function has many parameters and options, MessageDlg will only take advantage of a few (title, text, buttons).

Finally, you end up simply using MessageDlg and Delphi determines if an old school dialog form is to be created or the new more nicer task one. Problem solved, let’s move on to other bugs… Well, not so fast!

TaskDialog Width & Long Text Truncation

One of the nasty features of TaskDialog internal implementation is that it will try to determine on its own what should be the width of the dialog. The text you specify to be displayed will be wrapped and displayed in several lines. This is, of course, something you would expect.

However! If the text to be displayed is constructed entirely of non-breakable characters (no spaces and alike) and is longer than some 50 (or so) characters, the display will get truncated and ellipses will be injected into the final display!?! TaskDialogs do not grow in width if “more” text is to be displayed – they grow in height and truncate/ellipsesize the message text. Old school dialog form on Windows XP will grow in width until it reaches screen size – and will not truncate the message for the user in any way!

Truncation / Ellipsesization Visualized

I’m running this on Windows 7, themes enabled.

I need to display the full file name of a file where the path does not contain any spaces (which seem to be default “wrap here” characters). Let’s pretend this file should be displayed (has some 250 characters, no intervening spaces) in a dialog:

  LongFileName = '\\server\sub-folder-name\folder0123456789folder0123456789\another-folder\morefolders\a-directory\another-directory\morefolders\morefolders\a-directory\another-directory\morefolders\a-directory\another-directory\somefile-using-hypens-in-long-filename.txt';

First, using the TTaskDialog component and only setting a few properties:

TaskDialog1.Caption := 'TaskDialog1';
TaskDialog1.CommonButtons := [tcbOk];
TaskDialog1.Text := LongFileName;

Result :

Trying with MessageDlg as

  Format('This file has a very long path: %s', [LongFileName]), 
  mtInformation, [mbOk], -1);


Proof that MeesageDlg uses TaskDialog internally :)

Btw, you cannot set the width of the MessageDlg. Neither the “TDF_SIZE_TO_CONTENT” seems to help.

I Don’t Need (read: Want) No Truncation!

I really, really want to display the entire file path to the user with no truncation and ellipses.

Let’s try using the WrapText (SysUtils.pas) function:

    'This file has a very long wrapped path: %s',
  mtInformation, [mbOk], -1);


Better! Note that WrapText has 2 overloads and the more simple one has a property “MaxCol” which defaults to 45 (have no idea why).

However, 45 is not enough, I want the line to be some 80 or so characters, so trying with the following

    'This file has a very long wrapped path: %s',
    [WrapText(LongFileName), 80]), 
  mtInformation, [mbOk], -1);

Oh no! Again, truncation and ellipses – why oh why?!

Finally, after spending too much time on all this I’ve decided for the next option as the kind-of-I-can-live-with-it best one:

UseLatestCommonDialogs (not in this occasion, please)

Getting away from the whiny new task dialog and disabling UseLatestCommonDialogs:

UseLatestCommonDialogs := false;
    'This file has a very long wrapped at 80 path: %s', 
    [WrapText(LongFileName, 80)]),
  mtInformation, [mbOk], -1);
UseLatestCommonDialogs := true;


I’m not too happy with this – as the old school/style dialog is displayed – but I simply have to show the full file path to the user: no truncation or ellipses are allowed for me.

Do you have any idea how this can be better solved?

(I’m not looking for another 3rd party solution or some special one-time workarounds)

by zarkogajic at November 07, 2014 04:04 PM

The Wiert Corner - irregular stream of stuff


While researching the manifest problem I will post about next week, I made a short list of free Windows Resource Editors:

All other resource editors I found were not free, and someof them not maintained for an even longer period than the free ones.


Filed under: Delphi, Delphi 2, Delphi 2005, Delphi 2006, Delphi 2007, Delphi 2009, Delphi 2010, Delphi 3, Delphi 4, Delphi 5, Delphi 6, Delphi 7, Delphi XE, Delphi XE2, Delphi XE3, Delphi XE4, Delphi XE5, Delphi XE6, Delphi XE7, Development, Power User, Software Development, Windows, Windows 7, Windows 8, Windows Server 2000, Windows Server 2003, Windows Server 2003 R2, Windows Server 2008, Windows Server 2008 R2, Windows Vista, Windows XP

by jpluimers at November 07, 2014 05:00 AM

November 06, 2014

Castle Game Engine news

New features of our build tool for Windows...

New features of our build tool for Windows programs: we now automatically include an icon and create version information and manifest in the exe file. This makes exe files compiled using our build tool look again modern on new Windows versions :) The author and icon information in CastleEngineManifest,xml will also be reused for packaging on other platforms, e.g. for Android apk, Mac OS X application bundle and so on.

November 06, 2014 06:28 PM

The Wiert Corner - irregular stream of stuff


The last couple of weeks I taught two sessions at both ITDevCon 2014 in Milano, Italy and EKON 2014 in Köln, Germany.

The EKON materials are slightly more up to date and elaborate (sessions there were 75 minutes), so below are all the links.


  • I’ve switched to Markdown for presenting as that is very version control friendly
  • GitHub very good at handling relative links from your Markdown files to other resources, that I’ve switched the Conference repository to GitHub from BitBucket.
  • Somewhere over the next few months, the repository will convert from Mercurial to Git and also move to GitHub.

Unit testing:

Directory with documents:

Document page:


Build Automation:

Directories with documents:

Actual document pages:


Enjoy it!


Filed under: Delphi, Delphi 2007, Delphi 2009, Delphi 2010, Delphi x64, Delphi XE, Delphi XE2, Delphi XE3, Delphi XE4, Delphi XE5, Delphi XE6, Delphi XE7, Development, Software Development

by jpluimers at November 06, 2014 11:00 AM

Firebird News

GoLang driver supports Firebird wire protocol 11

GoLang firebird driver suports firebird wire protocol 11 (implemented in firebird 2.1) More info via nakagami’s blog

by mariuz at November 06, 2014 09:26 AM

The Wiert Corner - irregular stream of stuff


Two interesting links today about Delphi and Batch files.


PS: If you want to see some serious Batch file and PowerShell related scripts, then read through the Build Automation part of my session materials I posted to ITDevCon and EKON session materials on Delphi Unit Testing + Build Automation and Continuous Integration on-line.

More details are in the batch files here:

and PowerShell scripts here:

Filed under: Batch-Files, Delphi, Delphi 2005, Delphi 2006, Delphi 2007, Delphi 2009, Delphi 2010, Delphi 7, Delphi XE, Delphi XE2, Delphi XE3, Delphi XE4, Delphi XE5, Delphi XE6, Delphi XE7, Development, Scripting, Software Development

by jpluimers at November 06, 2014 05:00 AM

November 05, 2014

twm’s blog

When CloseHandle does not close the handle

Today I spent several hours hunting down a problem with opening a COM port. Basically the program opens a COM port, writes some bytes to it, reads an answer and closes it again. This determines whether the expected device is connected to the COM port or not.

If the answer is the expected one, so the device is connected and active, the detection loop exists (the COM port has been closed using CloseHandle).

Now the actual communication with the device starts. The first thing is does, is open the same COM port again. Which fails with the error code 5 (ERROR_ACCESS_DENIED). WTF?

Of course, I tried to debug the issue using the Delphi integrated debugger. While I stepped through the code, the error disappeared, only to come back when I just run the code without stepping through it. This was reproducible (I love reproducible errors.).

When something like this happens, you can be sure it is a timing issue. Either your program is multithreaded and the issue is one thread doing something while the other is doing something else that conflicts with the first thread (called race condition or deadlock, depending on the outcome). Or it’s not your own threads but somebody else’s.

In my case this StackOverflow question seems to be about the same issue and the accepted answer was mentioning the FTDI drivers I am using (the COM port is actually a USB serial adapter). These drivers apparently do not immediately close the port when the handle is closed so opening it again can fail. It turned out that a retry loop when opening the COM port solved the issue. Here is the code I ended up using:

procedure TCustomComPort.CreateHandle;
  MAX_TRIES = 10;
  Tries: integer;
  OK: boolean;
  Tries := 0;
    FHandle := CreateFile(
      PChar('\\.\' + FPort),
    OK := (FHandle 
    if not OK then
      Sleep(10 * Tries); // it wasn't enough to Sleep(10) here
  until OK or (Tries >= MAX_TRIES);

  if not OK then
    CallException(CError_OpenFailed, GetLastError);

Some of you might recognize part of this code from the ComPort library for Delphi and C++. (But probably not, because the original code is just three lines. ;-) )

Of course the real debugging was more complex than I described above because the program is multi threaded and the detection is done in one thread while the actual communication is done with the foreground thread writing to the port and the answers being processed by a background thread. So of course, at first I suspected an error in my code, actually found one, fixed it, just to run into the next problem. Finally it turned out to be the driver problem described here.

by dummzeuch at November 05, 2014 05:49 PM

The Wiert Corner - irregular stream of stuff


An interesting statement by Steve Maughan:

Looking at how many High DPI awareness or lack of is the developers Y2K of our time.

Looking at the trouble Windows and Windows applications in general have with High DPI (more in general: resolution independence). I think it rates even higher: as the EUR introduction problem of our time.

What do you think?


via High DPI awareness is must have feature for XE8. Not only for Delphi IDE, but….

Filed under: .NET, C++, Delphi, Development, Software Development, WPF

by jpluimers at November 05, 2014 05:43 PM

Firebird News

PyFirebirdsql Version 0.9.5 is released with Wire Protocol 11

PyFirebirdsql Version 0.9.5 is released with Firebird Wire Protocol 11 support. More info via nakagami’s blog Firebird Wire Protocol 11 was introduced in Firebird 2.1 What is left is protocol 12 introduced in Firebird 2.5 Protocol 13 is already implemented (Firebird 3.0)

by mariuz at November 05, 2014 03:08 PM

IBO 5.5.5 Build 2152 Released

Jason Wharton wrote on ibolist: I have released a new version of IB Objects. The primary objective of this release is to provide support for RAD Studio XE7. There have been some bugs fixed as well. Please see the release notes for details:

by mariuz at November 05, 2014 12:26 PM

The Wiert Corner - irregular stream of stuff

The kind of text that the Delphi IDE often removes in a .dpr file.

Vin Colgin posted on G+:

The kind of text that the Delphi IDE often removes in a .dpr file.

The kind of text that the Delphi IDE often removes in a .dpr file.

FastMM4 and lines in the *.dpr

I’ve got an old problem, in which the IDE will take the lines required out of the “uses” clause in the *.dpr. Something I’m sure we’re all aware of, but is there a solution to keep it from doing it?

The comments indicate the problem is less severe in more recent Delphi versions:

Daniela Osterhagen Actually it has become much better. The IDE doesn’t meddle as much with the DPR files as it used to.

One option for solving this issue is adding a new unit as the first entry that permanently stays there and moving the ifdef to that unit.

That’s what I did a long time ago and even put on-line, and even put it on-line at CodePlex as FastMM4BootstrapUnit.pas. Too bad CodePlex isn’t indexed on Google, so I commented this:

I’m using a FastMM4BootstrapUnit for that at the top of my DPR; it  looks like this [...]

It will eventually end up at my repository any way.Let me know if you need it there soon, and I can probably get something published after the Entwickler Konferenz next week.

So various people are now using this:

  • Vin Colgin:  very nice. Thanks for the tip!
  • Warren Postma: This works fine for me in xe6 and up.
  • Bruce McGee: Nice. May I steal this? And by “steal”, I mean giving credit in the code comments.

Since I could use this unit during my EKON 2014 talk about Delphi Unit Testing, I expedited the publication:

And explained the usage in this Unit testing session session materials.

Note: this file isn’t indexed either (as BitBucket doesn’t allow it), but since the repository will be git based in the foreseeable future anyway, I can then move it to GitHub which does allow Google to crawl the master branch.


via FastMM4 and lines in the *.dpr I’ve got an old problem, in which the IDE….

Filed under: Delphi, Delphi 2005, Delphi 2006, Delphi 2007, Delphi 2009, Delphi 2010, Delphi 3, Delphi 4, Delphi 5, Delphi 6, Delphi 7, Delphi x64, Delphi XE, Delphi XE2, Delphi XE3, Delphi XE4, Delphi XE5, Delphi XE6, Delphi XE7, Development, Software Development

by jpluimers at November 05, 2014 11:00 AM

Firebird News

ANN: Firebird PHP Generator 14.10 released

SQL Maestro Group announces the release of Firebird PHP Generator 14.10, a frontend to generate feature-rich CRUD web applications for your Firebird database. The software comes in both Freeware and Professional editions. This major release introduces new and updated controls, powerful JavaScript API, enhanced customization features, user-defined authorization, new application level events, multi-group menus and […]

by SQL Maestro Team at November 05, 2014 07:33 AM

The road to Delphi

VCL Styles Utils – Major Update (Dialogs, ProgressBar, DateTimePicker, ListView and more)

A Major updated was made to the VCL Styles Utils project. This version include several fixes and new features.


The Vcl.Styles.Hooks unit is the most updated part of this new release. This unit is the responsible of hook some of the UxTheme and WinApi methods like DrawThemeBackground, GetSysColor and GetSysColorBrush. Which allows take the control of the painting process for the system themed (and owner-draw) controls.


This new release fix the highlight color used on the selected items and also replace the themed checkBox by a styled checkbox.

ListView with VCL Styles
2014-11-04 11_08_19-Demo

ListView with VCL Styles + Vcl.Styles.Hooks unit
2014-11-04 11_08_55-Demo

Also was added support for style the Listview groups.

ListView with VCL Styles

2014-11-04 11_11_23-Demo

ListView with VCL Styles + Vcl.Styles.Hooks unit

2014-11-04 11_12_45-Demo

DateTime Controls

The Styling of the TMonthCalendar and TDatetimepicker components is one of the limitations of the VCL Styles, because such components are owner-draw by the system and doesn’t allow to customize the look and feel when the native themes are enabled (for more information read these TMonthCalendar and TDatetimepicker ) also only the newest versions of Delphi includes a partial styling support for such components. With this new release the styling of these controls is now possible.

TDateTimePicker and TMonthCalendar with VCL Styles

2014-11-04 11_29_24-Demo - RAD Studio XE7 - uMain [Running] [Built]

TDateTimePicker and TMonthCalendar with VCL Styles + Vcl.Styles.Hooks unit

2014-11-04 11_54_31-Demo - Embarcadero RAD Studio XE2 - Vcl.Styles.Hooks [Running] [Built]


Improved support for the TProgressbar component without flicker and with Marquee style.

2014-11-04 14_48_10-Demo

Select Directory Dialog

The styling for the select directory dialog was enhanced adding support for the open and close glyphs and fixing the color of the highlight bar.

VCL Styles Utils

2014-11-04 15_01_14-Browse For Folder

VCL Styles Utils + Vcl.Styles.Hooks unit

2014-11-04 15_01_52-Greenshot

Open/Save Dialog

The VCL Styles support of the Open and Save dialogs was improved adding styling for groups and highlight items. Also a fix for the select folder combobox was introduced.

VCL Styles Utils

2014-11-04 15_12_50-Open

2014-11-04 15_20_49-Open

2014-11-04 15_26_07-ThemedSysControls - Embarcadero RAD Studio XE2 - ThemedSysControls.dproj [Runnin

VCL Styles Utils + Vcl.Styles.Hooks unit

2014-11-04 15_14_27-Open

2014-11-04 15_21_25-Open

2014-11-04 15_25_16-Edit Post ‹ The Road to Delphi - a Blog about programming — WordPress

by Rodrigo at November 05, 2014 02:02 AM

The Podcast at

Developing on the Samsung Gear Live Smart Watch

Previously I created a blog post about using Delphi and RAD Studio XE7 to develop for the Moto 360. The new FireUI Multi Device Designer (MDD) makes is a breeze to design for the new smaller UI. I’ve since updated the FireUI Devices project on GitHub to cover the Samsung Gear Live & LG-G watches in addition to the Moto 360.

I thought I would walk through the steps for developing with the Samsung Gear Live. One advantage it has over the Moto 360 is that it has a physical USB cable connection, so you don’t need to deploy via BlueTooth. This makes for a much faster deploy cycles. With a USB cable though, you need to install the ADB USB Drivers.

  1. Put the device in USB Debugging Mode
    1. Hold the home / side button until the settings menu appears (couple seconds)
    2. Select About and tap Build Number until it notifies you that developer options are enabled.
    3. Swipe left to right to go back
    4. Select Developer Options and enable USB Debugging.
  2. You still need to have the watch paired with a phone via the Android Wear app since the confirmation dialog is displayed there.
  3. Run the SDK Manager / Android Tools and Make sure you have Android SDK Tools, Platform-tools and Build tools updated (this moves the ZipAlign.exe, so you need to tell the IDE where to find it.)
  4. Install the Samsung Android USB Driver for Windows
  5. Gear Live should appear as an Other Device in device manager once you connect it to windows via USB.
  6. Select Update Driver Software
  7. Browse my computer for Driver software
  8. Let me pick from a list of device drivers on my computer
  9. Then select ADB Interface
  10. Select SAMSUNG Android ADB Interface
  11. On your phone you will see a dialog “Allow Wear Debugging” Check “Always allow .. . ” and then select OK.

Gear Live - Device Manager Driver Update


Once you have done all of that, it will show up in your IDE as a target, and when you load the FireUI custom device for it, then you will have a great design surface for it too.

GearLive in XE7 IDE


And you are ready to build your Gear Live app with Delphi XE7.

Delphi XE7 on the Samsung Gear Live

I’m sure I’ll have more coverage on Android Wear in the coming months too.

by Jim McKeeth at November 05, 2014 01:03 AM

November 04, 2014

Firebird News

Firebird Django 1.7 support (experimental)

Maximiliano Robaina wrote on django-firebird-dev list I just upload a new branch into the main repository. This new branch “develop” [1] has the implementation to support django 1.7. I’ll like have got some feedback about it, so just clone the repo and switch to “develop” branch to try with django 1.7. Let me know what […]

by mariuz at November 04, 2014 04:16 PM

twm’s blog

class as interface: Operator not applicable to this operand

Once in a while I run into this problem and every single time it takes me forever to remember the cause:

Say, you have got an interface and a class implementing that interface:

  IMyInterface = interface
    function asMyInterface: IMyInterface;

  TMyClass = class(TInterfacedObject, IMyInterface)
    function asMyInterface: IMyInterface;


function TMyClass.asMyInterface: IMyInterface;
  Result := Self as IMyInterface; // compile error here

This will fail to compile in the marked line with the error “Operator not applicable to this operand type”.

The reason is simple: In order for the as operator to work on interfaces, the interface must have a GUID assigned to it. You do that in the Delphi IDE by positioning the cursor after the interface keyword and press Shift+Ctrl+G. As soon as your interface declaration looks like this …

  IMyInterface = interface ['{93903D10-58F7-41B0-AFB1-2A8E17F828EF}']
    function asMyInterface: IMyInterface;

… the code will compile.

(Don’t just copy this code, you will need to generate your own unique GUID as described above! Otherwise you will experience strange things.)

by dummzeuch at November 04, 2014 03:11 PM

The Wiert Corner - irregular stream of stuff


Like any long term project (Spring4D took about 5 years to release version 1.0 and still needs a lot of mobile polising) the “Delphi Parallel Library” took a long time to complete.

It got incorporated as the “Parallel Programming Library” in Delphi XE7.

Since the documentation is thin (like Spring4D <g>), but the posts about “Delphi Parallel Library” (those started in 2008!) give a lot of background information.

Hence the reminder to self.

Now I need to compare this to the Omni Thread Library for Delphi (which is on version 3+ now) one day (:

(PPL is cross platform whereas OTL is not, but there must be much more differences).


Filed under: Delphi, Delphi XE7, Development, Software Development

by jpluimers at November 04, 2014 11:41 AM


Normally you would not want to use a reserved word as an identifier. But sometimes it can be very convenient, for instance for a code generator that wraps remoting calls or does ORM.

Both Delphi and C# have an escape for this:

The prefixes are to tell the compiler knows you really know what you are doing, and are using a reserved word as an identifier.

The cool thing: in the Run Time Type Information (Delphi) or Reflection (C# and VB.NET) you will see the names without the prefix.

Some examples from StackOverflow:

& prefix for Delphi

private &string: Integer;

Kenny Cason answered delphi – Is it possible to use reserved words for field names? – Stack Overflow.

@ prefix for C#

private long @string;

Jon Skeet answered Use the long reserved word as a variable name in C# – Stack Overflow.

[] embedding for VB.NET

Private [string] As Integer;

Tobias Wittenburg asked – Reserved Keyword in Enumeration in C# – Stack Overflow.

The VB.NET way also works in Microsoft SQL Server and Microsoft Access.

“” embedding in many SQL syntaxes


Exception: Microsoft SQL Server and Microsoft Access use [] embedding.


Some SQL implementations uses the embedding not only to allow for reserved words, but also to allow embedding spaces in identifiers.

Delphi, C# and VB.NET cannot do that, so be aware of that when performing ORM work.


Filed under: .NET, .NET 1.x, .NET 2.0, .NET 3.0, .NET 3.5, .NET 4.0, .NET 4.5, C#, C# 1.0, C# 2.0, C# 3.0, C# 4.0, C# 5.0, Delphi, Delphi 2005, Delphi 2006, Delphi 2007, Delphi 2009, Delphi 2010, Delphi 8, Delphi XE, Delphi XE2, Delphi XE3, Delphi XE4, Delphi XE5, Delphi XE6, Delphi XE7, Development, Software Development, VB.NET, VB.NET 10.0, VB.NET 11.0, VB.NET 7.0, VB.NET 7.1, VB.NET 8.0, VB.NET 9.0

by jpluimers at November 04, 2014 05:00 AM

November 03, 2014

Firebird News

New Documentation Development funding – New button labelled : Fund Docs using PayPal.

Donation page is now updated so you can contribute to that sepecific fund On 31 October, 2014, the Firebird Project released the Firebird 2.5 Language Reference in Russian, a large documentation task sponsored by Moscow Exchange, one of the biggest Firebird users in the world, and IBSurgeon (tools and services for Firebird). Several Russian-speaking […]

by mariuz at November 03, 2014 02:05 PM

Firebird 2.5.3 updated in #Debian unstable with fb_guard lock file permissions fixes

Firebird 2.5.3 is updated in Debian unstable with minor security fixes Here is the changelog : * add patch tightening fb_guard lock file permissions (Closes: #767497) Thanks to Holger Levsen *-super.postinst: tighten permissions on existing fbguard lock file * declare conformance with Debian Policy 3.9.6

by mariuz at November 03, 2014 09:54 AM

Database .NET 13.5 released

Database .NET is an innovative, powerful and intuitive multiple database management tool, With it you can Browse objects, Design tables, Edit rows, Export data and Run queries with a consistent interface. New features and improvements from 13.1 to 13.5 (2014/11/03) Added Binding Procedure and Function parameters Added Binding SQL variables Added (De)Compression and (De)Encoding strings […]

by fishcodelib at November 03, 2014 06:40 AM

October 31, 2014

Firebird News

Firebird Language Reference in Russian is ready. Do you need it in English?

Firebird Project is pleased to announce that Firebird 2.5 Language Reference in Russian language is released. It is available on Firebird SQL Documentation page. Why it is only in Russian and how to get it in English? The answer is the following: Moscow Exchange, one of the biggest Firebird users in the world, and IBSurgeon […]

by mariuz at October 31, 2014 02:23 PM

The Wiert Corner - irregular stream of stuff


Last week, I viewed to webinars. A smaller one Geek Fest – Automating the ForgeRock Platform Installation about Ansible installation of Unix machines, and the first 70% of the last day ofCodeRage 9 | Free Development Event by Embarcadero.

Both had a bad experience because of GoToWebinar has a really bad user experience.

  1.  When a GoToWebinar connection terminates, the GoToWebinar client closes. You loose everything in the Q&A log. You need to hope someone else saved the Q&A log so you can see the public questions, but the private comments you made are gone.
  2. It is impossible to install the Windows client when you are behind a McAfee Web Gateway that filters downloads and HTTPS traffic. After trying for about 15 minutes, we gave up and reverted back to a Mac over another connection. It meant we could not use the conference room and had to cram many people behind a small MacBook screen.
  3. The Mac OS X client does not allow you to resise the Q&A log, so even on a 4k display, you can see like 10 lines of Q&A.
  4. When there are many attendees, the refresh rate slows down from sub second to once per 5-10 seconds, this is really bad when watching demos of software: a big aim of webinars.

When terminating, the only thing GoToWebinar allows you to do is give feed back (too bad they don’t allow for detailed feed back). So I gave it 0 out of 5 stars.


PS: I could save the below Q&A logs. If you have other logs, please let me know so I can publish them. I’m especially interested in Have You Embraced Your Inner Software Plumber Yet? by David Schwartz – The Tool Wiz

These are the  CodeRage 9 – Object Pascal Sessions I could save the Q&A log of:

Filed under: Appmethod, Chrome, Delphi, Delphi XE7, Development, FireFox, Internet Explorer, Power User, Software Development, Web Browsers Tagged: GoToWebinar

by jpluimers at October 31, 2014 06:24 AM

October 30, 2014

The Wiert Corner - irregular stream of stuff



Creating Beautiful Animations in your Desktop and Mobile Applications

The session demonstrates how to create beautiful timeline-based animations in Object Pascal using the Mitov Software’s AnimationLab.

Level: All
Boian Mitov – Mitov Software


Welcome to CodeRage 9 – Object Pascal Track! Track Schedule:

Audience Question

  • Q: It’s unfortunate that GoToMeeting only shows about 1 frame a second, which doesn’t do justice to the animations that the author is trying to show.
  • A: :-( They look great here.

Audience Question

  • Q: about Codesite have there been session in previous Coderage ?
  • A: I believe so.

Audience Question

  • Q: Of COURSE the animations look great over there. You are seeing them at a much faster frame rate than GTM transmits!
  • A: :-D

Audience Question

  • Q: WOW! Great components Boian, In the FireMonkey edition, can any descendant of TShape, such as Raize new Radiant components?
  • A: It works with any component via LiveBindings.

Audience Question

  • Q: Please, tell about Mitov.Runtime library.
  • A: Contact Boain for more information

Audience Question

  • Q: Is your SignalLab able to be used on Android and iOS?
  • A: Not yet, but coming soon.

Audience Question

  • Q: I dont find info about Mitov.Runtime on the homepage. Where can we find more info about it?
  • A: Email Boian. It isn’t published yet.

Audience Question

  • Q: Is there some video capture possibilities now, harvesting the activity together with speech to make videos from lessons etc. etc. (Like those made to prepare this lesson)
  • A: Perhaps.

Audience Question

  • Q: Do you support XE7?
  • A: Absolutely.

Audience Question

  • Q: Do you support XE7?
  • A: in Prerelease. Just finishing documentation.

Audience Question

  • Q: What are the different effects in the Physics engine?
  • A: Mass and drag (like fluid) effects only. Feel free to suggest other effects

Audience Question

  • Q: In the past ~2007 I had tried to use Myour lab for signal processing like FFT with scopes etc. but found it was not able to get support. Looks like that time in the past and Mitov now is a mature company and doing well.
  • A: Hope so.

Audience Question

  • Q: Is open wire in firemonkey
  • A: Yes, supports both VCL & FireMonkey, so works with non-visual too.

Audience Question

  • Q: Did I hear right – no iOS support?
  • A: Correct. Just don’t have an iOS device to develop and test on. Looking for it come in about a month.

Audience Question

  • Q: Thanks for great demo!
  • A: :-)

Audience Question

  • Q: Thank you!
  • A: :-)

Audience Question

The registered user download page

Audience Question

Audience Question

Audience Question

Audience Question

  • Q: Yes, got a refreshing today :-)
  • A: :-)

Audience Question

  • Q: yes its in the list
  • A: :-)

Audience Question

  • Q: There is nothing special in converting from VCL to FireMonkey from XE6 to XE7… that’s why…
  • A: :-)

Audience Question

  • Q: thanks
  • A: :-)

Audience Question

  • Q: ^ mida xe7
  • A: Thanks!

Audience Question

Audience Question


via: CodeRage 9 – Object Pascal Sessions.

Filed under: Appmethod, Delphi, Delphi XE7, Development, Software Development

by jpluimers at October 30, 2014 09:05 PM



Advanced RTTI in Object Pascal

Runtime Type Information RTTI has always been a core feature of Delphi. But until recently, it was complex and limited. Now, RTTI is significantly more powerful, and yet much easier to use as well. This session describes in detail all of the changes that have been made and demonstrates the new capabilities with several examples including field inspection, method invocation, and custom attributes.

Level: Intermediate
Ray Konopka – Raize Software


 Q: I’ve put all of today’s chat logs at my blog indexed at

A: Great, thanks so much!

Audience Question

Q: If I should advise another tool nice for both program development, database development, project administration and brainstorming, it would be Mindjet Mind Manager 2014 Plus with Spigit Engage :-)

A: Nice

Audience Question

Q: Wirth what version of Delphji was extended RTTI introduced?

A: Delphi 2010

Audience Question

Q: Is there some literature on marshaling vs php on Linux servers? I now use a tool in Jedi JVCL for serializing using html/xml alike structures.

A: You can use RTTI

Audience Question

Q: Grate stuff, I can build new computer language by it!

A: :-)

Audience Question

Q: Is it possible to retrieve RTTI for strict private members?

A: Follow up with Ray via email.

Audience Question

Q: Using RTTI to access (private) fields directly would violate proper OO design. It would be better to have only the public fields, properties and methods being exposed/emitted by default.

A: Just because you can, doesn’t make it a good idea. Sounds like just the public properties are exposed by default.

Audience Question

Q: Can I use the adv. RTTI with any of my existing classes ? Like serializer for my classes ?

A: Should be able to.

Audience Question

Q: Is it possible to get class helper functions with RTTI ?

A: Not sure.

Audience Question

Q: Is it possible to get class helper functions with RTTI ?

A: Probably. Would need to experiment and see.

Audience Question

Q: The example of RttiMethod would work nice if you spell Create correctky, but perhaps you should have som try except to catch misspelled method names :-)

A: Good idea.

Audience Question

Q: Really great talk, Ray!

A: :-)

Audience Question

Q: Is there any way to add a field to an object? If no, what the best way to simulate?

A: maybe, with an agregate. Depends on what you are trying to solve.

Audience Question

Q: what is the immediate use of RTTI if i have the source code and can access all controls and data structures in code?

A: There are a lot of uses.

Audience Question

Q: support for records as well or just the classes ?

A: Records should have RTTI in the latest Delphi.

Audience Question

Q: I’ve used RTTI to design a flexible “security” system for applications– give administrators the ability to hide menu items, buttons, controls. Very useful for that.

A: :-)

Audience Question

Q: So essentially, it should be possible to create/add properties on-the-fly to classes/records based on scripts? this would be so powerful!

A: Not in the traditional sense. You would still need to manage the data, the object wouldn’t.

Audience Question

Q: field rtti for records was in 2010, for record methods came with like XE2 or later, rtti for record properties unfortunately still missing afaik :(

A: Good to know, thanks.

Audience Question

Q: Great Job Ray.

A: :-)

Audience Question

Q: If the application I am working on, should I care at all about RTTI?

A: Depends on what you are doing. Delphi uses for the designer.

Audience Question

Q: If you really need properties to be called from a script, then you should take a look at any of the Delphi Scripting engines: DWScript, TMS ScriptEngine, etc….

A: :-)

Audience Question

Q: Is there a list of projects in

A: Please send me an email and I can provide:

Audience Question

Q: Could you give the download link for the source code of your Effectively Using Generics in Object Pascal session again?


Audience Question

Q: Links for source code?

A: You can email Ray

Audience Question

Q: Links for source code?



via: CodeRage 9 – Object Pascal Sessions.

Filed under: Appmethod, Delphi, Delphi XE7, Development, Software Development

by jpluimers at October 30, 2014 08:05 PM



CodeRage 9 Files!

This year I presented Push notifications with Android. Here are the files mentioned in the session!


Android Push Notifications

Want to send push notifications to your clients or employees? This session goes over setting up GCM, installing push notifications into your application, and calling GCM to push those messages to your app.

Level: Intermediate
Jeff Lefebvre


Audience Question

  • Q: Are you going to release the videos on youtube? I would recommend it if you weren’t. Youtube has become the place where people search for training.
  • A: As for previous CodeRage events, CodeRage 9 replays will be available within 1-2 weeks after the conference concludees on the CodeRage website at

Audience Question

Audience Question

  • Q: Ummm DailyDeveloper – eh? Sory about that!
  • A: :-)

Audience Question

  • Q: CodeRage is also an anagram for CodeGear
  • A: I didn’t know that. Nice.

Audience Question

Audience Question

  • Q: On my Android SDK Manager I didn’t see anything of Google and some other options shown in your demo y\under Extras. Am the installation too old?
  • A: If you run the update once and then restart again it should offer you more options.

Audience Question

  • Q: great presentation! thanks
  • A: Yeah, I really enjoyed it too!

Audience Question

Audience Question

  • Q: Is it possible to show the last slide with links ?
  • A: There you go.

Audience Question

  • Q: Are there any limitations in terms of how many notifications can be sent, commercial use, etc?
  • A: AFAIK there is no limit.

Audience Question

  • Q: Why there are no build in componnets in Delphi for push notifications for iOS and Android?
  • A: There are push notification components in XE7

Audience Question

Audience Question

  • Q: What is a diffrence beetwen push notification from XE7 and GCM ?
  • A: The XE7 push notifications go through Kinvey, Parse or App42 BaaS providers and still use GCM, but abstracts out the complexity.

Audience Question

Audience Question

  • Q: Seems like push notifications could be a way to register historic places, like cots where people lived 150 years ago before emigrating to US in order to put them on historic maps whee the places today has other names
  • A: Sure

Audience Question

  • Q: Would be for research where places was, like finding leftovers in terrain and want to register that in a database together with name of place
  • A: If you wanted to.

Audience Question

  • Q: thanks jeff
  • A: no problem :)

was a pleasure! Now back to work lol

Audience Question

  • Q: What do I get if I renew maintenance?
  • A: You get another year of updates. Not sure about Rapid SQL, but you should get most of the other stuff. Talk to sales and they can give you the details.

Audience Question

  • Q: If people have a stair around they should probably go some trips up and down to increase blood circulation in legs :-D I’ll do that now :-D
  • A: Blood circulation is a good thing, I’d agree with you there.

Audience Question

  • Q: Was that a TLikable class?
  • A: Absolutely.

Audience Question

  • Q: Is Jim McK a codemonkey
  • A: Yes, I am a Code Monkey. ;-)

Audience Question

  • Q: I would advise those who like the Rapid SQL to upgrade to DBPower studio
  • A: Nice.



Filed under: Android, Android, Appmethod, Delphi, Delphi XE7, Development, Mobile Development, Power User, Software Development Tagged: android, Push notifications

by jpluimers at October 30, 2014 06:47 PM



Understanding Distributed Version Control

This session helps developers who have been working with a Centralized Version Control System such as SVN to understand and use Distributed Version Control such as GIT or Mercurial. This session focuses primarily on GIT, but applies to Mercurial. We also cover how to use GIT from the RAD Studio IDE.

Level: Beginning
Robert Love – State of Utah


Audience Question

  • Q: Can you say why you chose GIT over Mercurial?
  • A: Years ago I ran across a great blog post comparing both, as I had a hard time picking one. Ultimately I had to use GIT first on an Open Source project and got used to it, so I use it primarlly. I still have a few things I use that are with Hg. Overall one is not better than the other.
  • Q: Note the / is actually the slash, not the reverse slash (the \ is the back-slash, not a reverse slash either).
  • A: Thanks :-)
  • Q: Any way to speed up the refresh rate of GoToWebinar? A lot of what Robert Love shows can’t be seen as the webinar doesn’t keep up.
  • A: I can’t see a way to do this – Robert Love
  • Q: On my side, the GoToWebinar viewer refreshes like every 5-10 seconds, and I’m on a symmetric 50/50 megabit fiber connection.
  • A: Sometimes GoToWebinar gets slow, especially this time of the day. Sorry.

Audience Question and

Audience Question

  • Q: In SVN there is a revision number, is there something simular in git? We commonly put the SVN revision number in the version information on our executables, is there something simular one can do using git to identify what revision the program was built from?
  • A: Git has a hash number that tells you the revision, but it isn’t an incremting number.
  • Q: I favour Github over BitBucket especially for repositories containing documentation as GitHub allows you to have Markdown files referring relative locations to images and other URLs without getting broken. BitBucket has struggled for years to support that and still doesn’t.
  • A: :-)
  • Q: Since Github only supports Git (few hosters support Mercurial), that basically forced me to the Git side of DVCS.
  • A: :-)

Audience Question

  • Q: Git has also a far easier way of importing SVN than Mercurial: Git has it built in.
  • A: :-)

Audience Question

  • Q: The Distributed (briefcase) model works for Open Source projects, because noone is being paid any money. Example: One published Request is picked up by 10 developers, and when they all commit their Versions, usually only one is used, and the other nine’s work is completely/laregly wasted. So … I guess I don’t find this distributed model very compelling.Great Presentation though
  • A: If isn’t compelling, don’t use it. Git also has much better support for branching, merging, etc.

Audience Question

Audience Question

  • Q: is it possible RAD will support TFS?
  • A: I think I saw a plug in for that.

Audience Question

Audience Question

  • Q: Most of the demos I’ve seen have tidy demos involving text files, where merging seems relatively easy, as it would be with a .pas file – how do you find merging DFM files? (Which I’ve occasionally found tricky in SVN) Does Git/HNG make this easier?
  • A: Nothing handles DFM well if someone is changing the same area of the file. Git does pretty well if the changes are in different parts of the DFM.
  • Q: BitBucket has the huge advantage of freely hosting private repositories. On GitHub you need to pay for that.
  • A: Yes

Q: DVCS know about the changes to a file (and have the whole change tree locally) so are far better at merging van a state based system like SVN (though SVN has gotten better over the years)

Audience Question

  • Q: Version Control under Tools>Options is only available in XE7?
  • A: SVN has been there for a while, but Git is XE7

Audience Question

  • Q: I use SVN, and can see some nice things about SourceTree vs SVN. Did I miss why GIT might be better than SVN?
  • A: There are a lot of differences and advantages to Git.

Audience Question

  • Q: I work on sparetime with an ideal organisation that has its own server and today we have a svn repository. Seems like with git you miust o\upload souircecode to open soiurce repositories. I wonder is it possible to set up our own git server for own use?
  • A: Yes, absolutely. You can host your own private server or a private repository on other servers.
  • Q: Version numbers should not depend on the kind of repository one uses. It makes you technically dependant on the repository. So version numbers should come from your build integration.
  • A: :-)
  • Q: Git and Mercurial are great for working while not always being on-line.
  • A: :-)

Audience Question

  • Q: Duplicate work isn’t a function of the source control. Manage that through a bug tracking system.
  • A: :-)

Audience Question

  • Q: SourceConnexion not available for XE6 or XE7.
  • A: Send them an email and ask them to update.

Audience Question

  • Q: DVCS know about the changes to a file (and have the whole change tree locally) so are far better at merging van a state based system like SVN (though SVN has gotten better over the years)
  • A: :-)

Audience Question

  • Q: I’ve missed the Bluetooth as well as this current session – will it be available for download ?
  • A: Yes, 1 – 2 week.s
  • Q: The whole trick with any version control mechanism is to split work in such a way that you make the merges to be in disparate pieces of your code base (even when in the same file). Even though Git and Mercurial are far better at merging than for instance SVS, SVN and TFS, each merge is a risk.
  • A: Sure

Audience Question

  • Q: re: SourceConneXion – we have a license for it and tried to use it, but it’s not even close to what we need. No any support for XE6&7
  • A: Sorry.

Audience Question

  • Q: For info, there is also Gitlab ( if you want to host your own repositories. Fairly good and fairly feature rich
  • A: Thanks.

  • Q: Thanks for the great session. Well paced and well explained.
  • A: Your Welcome

Audience Question

  • Q: Do you have a tip for us how to treat common folders shared among projects?
  • A: GIT has a feature called SubModules that can do this.

Audience Question

  • Q: where does the name ‘CodeRage’ come from?
  • A: I believe “Rage” is to party or other excitement. So CodeRage is a Code Party or Code Excitement


via: CodeRage 9 – Object Pascal Sessions.

Filed under: Appmethod, BitBucket, CVS, Delphi, Delphi XE6, Delphi XE7, Development, DVCS - Distributed Version Control, git, GitHub, Mercurial/Hg, Software Development, Source Code Management, SourceTree, Subversion/SVN, TFS (Team Foundation System)

by jpluimers at October 30, 2014 06:19 PM



Bluetooth Classic and LE Programming with VCL and FMX

Level: Intermediate
Diego Navarro – Embarcadero


Audience Question

Audience Question

  • Q: can you please paste links int the chat window
  • A: Which link? I don’t have them in text if they are from the video, so I am just typing them in.

Audience Question

Audience Question

Audience Question

  • Q: On PC’s there is a CAMERA ICON on the upper right. of the Webinar window. I just snapshot the interesting pages and follow links later.
  • A: Good tip David!

Audience Question

Audience Question

Audience Question

Audience Question

  • Q: There is currently no common Bluetooth low energy Application Program Interface (API) for Android devices available
  • A: TBluetoothLE

Audience Question

Audience Question

  • Q: The sensor tag use BLE that is implemented in BT4.0. To work with Android you need Android with BT4.0 and OS 4.3+ (older version of Android doesn’t support BT 4.0)
  • A: Correct. :-)

Audience Question

  • Q: Can the Sensor tag be used with Android?
  • A: Yes, of course

Audience Question

  • Q: What is the accuracy of the gyroscopic sensor of SensorTag?
  • A: It’s really nice, the same chip is used in a lot of other devices, it’s not just a toy :)

Audience Question

  • Q: There is currently no common Bluetooth low energy Application Program Interface (API) for Android devices available
  • A: Yes, there is, since Android 4.3

Audience Question

  • Q: How can we find “custom” services from a Arduino Bluetooth LE Shield ? My app find the device but no services
  • A: It depends if the device is advertising the services.

Audience Question

  • Q: Got that now — apparentyl my Nexus 7 (2013) has it — so I’m OK
  • A: Good.

Audience Question

  • Q: Got that now — apparentyl my Nexus 7 (2013) has it — so I’m OK
  • A: yep, you Nexus 7 is fine for Bluetooth

Audience Question

  • Q: Can last connected device data be stored and be restored when app reboot?
  • A: it’s not useful, you can start doing a new startDiscover to get the devices around.

Audience Question

  • Q: Can I send binary data trough bluetooth?
  • A: Yes, right, you can, but Bluetooth LE is not intended for that, the bandwidth is so small, around 1 kB/s (LE)

Audience Question

  • Q: Can you provide a link where we could download the source code of your demo?
  • A: Diego will provide a download link for the sensor tag. You can find the rest with the samples folder.

Audience Question

  • Q: Working on Android with TBluetoothLE component i noticed that subscribe characteristic work only with the device/sensor that support notification property and not indication property. It is possible? Is something that will be available on update1? Thanks
  • A: That should be working.

Audience Question

Audience Question

  • Q: Do you know if the BLE component works with BT devices implemented Mesh technology?
  • A: Need to check. Unsure.

Audience Question

  • Q: How can we get the UUID of the device found?
  • A: Not recommend. Look for devices that implement the service you need.

Audience Question

  • Q: DavidI, where can I see your awesome video,”codemonkey”? I want to see it again. It’s parsonal question..
  • A: This is Jim. I’ll try to find an opportunity to show it again today. It isn’t available anywhere but here yet.

Audience Question

  • Q: Mesh technology is kind of distributed network of BT devices that connect each other to spread the BT messages to devices that can be out of range.
  • A: It should work.

Audience Question

Audience Question

  • Q: One hint: don’t forget to add “bluetooth” to the uses permissions on android.
  • A: Good tip.

Audience Question

  • Q: Can we find or uses non advertised “custom” services?
  • A: You need to know about the UUID and sservices and then you can connect and use them.

Audience Question

Audience Question

  • Q: Will order a sensor and give this a try $25 — spent more on lunch most days. :-) Digikey, Newark and Mouser carry them if you need some help finding one. Also the TI store.
  • A: :-)

Audience Question

  • Q: The radio rate is 2Mb/sec. I suspect mesh is limited or impractical. The spec doc should make it more clear. Only 354 pages — happy reading. Link above.
  • A: :-)

Audience Question

  • Q: Diego Navarro blog address?
  • A: Stay tuned to and I will make sure and link to his post when it is available.

Audience Question

  • Q: In proprietary mode, the CC2541 radio supports data rates up to 2 Mbps, and has extensive baseband automation, including auto-acknowledgment and address decoding. The RF Core controls the analog radio module and the RF transceiver state. In addition, it provides an interface between the MCU and the radio which makes it possible to issue commands, read status, and automate and sequence radio events. It has 1 KB of dedicated RAM, which holds the 128-byte transmit and receive FIFO. This chapter describes the proprietary mode operation of the CC2541 devices and features in the LLE program. For Bluetooth low energy operation, see Chapter 24.
  • A: Thanks!

Audience Question

  • Q: this just gets better and better every time I see it
  • A: Thanks!

Audience Question

  • Q: Great presentation! especially the TI sensor implementation .
  • A: Yes, I agree.

Audience Question

  • Q: DavidI, I am sad that I can’t find the page of “;. It causes 404 error.
  • A: Yes, it isn’t available yet. I’ll have the video online soon. For now it is just for CodeRage attendees. BTW, this is Jim McKeeth. ;-)

Audience Question

  • Q: We all have our pet projects in delphi. Here’s mine. Halloween light show with sound in my front yard controlled by delphi DMX Lighting system platform I created.
  • A: Nice

Audience Question


via: CodeRage 9 – Object Pascal Sessions.

Filed under: Appmethod, Delphi, Delphi XE7, Development, Software Development

by jpluimers at October 30, 2014 04:55 PM



InterBase Keynote

If you need to manage distributed data over multiple locations then don’t miss the product address for InterBase! The next generation of InterBase is coming soon and will be super charged with a powerful new change tracking engine that makes managing distributed datasets a whole load easier!

Level: All
Stephen Ball – Embarcadero


Audience Question

  • Q: Off topic: Has their been any reports of issues with Yosemite and virtual machines (VMWare)? I am planning on updating my OS X this weekend.
  • A: I know Parallels has released an update to work with Yosemite. It is pretty common that you need a new version to support a new OS. I’d check with VMWare to see if they have an update or what they recommend. I haven’t updated yet because I’ve been so busy with CodeRage and everything, but plan to upgrade both Parallels and OS X next week.

Audience Question

  • Q: just changed
  • A: Sorry.

Audience Question

  • Q: Paralles 9 still works on Yosemite. However, 10 is supposed to work more efficiently.
  • A: Good to know.

Audience Question

  • Q: I’m using Parallels along with Yosemite and Windows 10 without any problems!
  • A: Nice.

Audience Question

  • Q: No problem. Looks like he was on the first slide whole time.
  • A: There was an intermediate slide but the screen was hung. My falt. Sorry.

Audience Question

  • Q: Parallels 9 have issues with Windows 10 and Yosemite. You must upgrade to Parallels 10.
  • A: Good to know.

Audience Question

  • Q: if i need to database 1 million news stories aday and proive a search functionality on headlines and story bodies where you can do word seach or phrase search for over 100 people, is interbase a good solution or is a noSQL better?
  • A: InterBase gives you User Defined Functions for searching. So there are ways to add search. There are other advantages too.

Audience Question

  • Q: does IB support #memory tables as in SQL ?
  • A: Not Memtables, but you can use FireDAC and InterBase supports Temporary Tables. So it depeds on your use case.

Audience Question

  • Q: meant caching tables within the engines
  • A: The caching algorythems optimize to use the memory you provide the database to keep the tables in memory.

Audience Question

  • Q: Excellent!! never looked at IB seriously, will join th BETA. thanks for the great presentation
  • A: :-)

Audience Question

  • Q: I have sampled audio/Seismic streams and stored on IB — several hundred and several thousand samples per second for 24 hours — that’s several GByte per day. A decent Linux server lets this work fine.
  • A: :-)

Audience Question

  • Q: perfect – looking forward to the Beta
  • A: :-)

Audience Question

Audience Question

  • Q: btw someone know any map to “translate” mac keyboard to windows i toke me 1 hour to find backslash
  • A: Some of the Virtual Machine software suppors that. Beyond that I am not sure.

Audience Question

  • Q: The barcode really does work if your tablet is handy. Only caught the second one though. It was the first one I wanted. Oh well — waiting for the replay!
  • A: We will ahve the replays in a week or two. You’ll get an email.

Audience Question


via: CodeRage 9 – Object Pascal Sessions.

Filed under: Appmethod, Database Development, Delphi, Delphi XE7, Development, InterBase, Software Development Tagged: InterBase

by jpluimers at October 30, 2014 04:30 PM



Working with PDF and Office Documents using VCL and FireMonkey

In this session, we take a deep look into the all-new multi-format document processing toolset for Delphi from Gnostice. We take a brief look at architectural details of the product and then go into using the product. You’ll get to see real code examples for viewing, printing, converting and processing documents in Delphi VCL and FireMonkey on Desktop and mobiles devices. You’ll also see examples of document processing using the new Gnostice REST-based document server.

Level: All
Girish Patil – Gnostice


Audience Question

  • Q: i wish there was a C++ to Delphi converter at least for porting code. So when I get a API sample from someone that’s in C++ i could just convert it to delphi and tweek it from there.
  • A: It would be nice.

Audience Question

  • Q: WIll this work as a document viewer for iOS and Android apps?
  • A: Yes, the native viewer for iOS will, but not yet for Android.

Audience Question

  • Q: How do you recommend controlling duplex and tray selection when printing several documents in one batch?
  • A: Currently not possible, unless you use the printer object.

Audience Question

  • Q: Is Android support in the works?
  • A: yes

Audience Question

  • Q: those it compress the final result PDF? can we teak it ?
  • A: there is compression. Working on improving it.

Audience Question

  • Q: If systools is needed for xe7 but isn’t in sourceforge, it only required creating a xe7 package. The source is compatible
  • A: nice

Audience Question

  • Q: If I wanted to create an app on the Mac, using FireMonkey, what would be the correct choice on the Website? ie: would “XtremeDevSystem Delphi Subscription 8″ be the correct choice?
  • A: That would be a good choice, but the XtremeDocumentStudio would do too

Audience Question

  • Q: It would be nice to have a LITE pdf viewer for firemonkey, that could read from files or streams.
  • A: There is a view, print and convert edition as well that you could look into.

Audience Question

  • Q: Can PDF’s be saved in PDF/A format?
  • A: Something in the works right now. Expect it early 2015

Audience Question

  • Q: Will it be compatible with C++Builder any time soon?
  • A: It is now.

Audience Question

  • Q: how about excel documents
  • A: Currently supporting the wordprosseing formations. Spreadsheets are coming next year.

Audience Question

  • Q: For sensitive data, you show phone and email, can you remove sensitive pages from documents such as Financial info pages from a document.
  • A: You would need to use two functions: Search to find the information and then delete page on that page.

Audience Question

  • Q: Is Signing and Verification supported?
  • A: Signing is supported. Verification is not. Signing requires the PDF toolkit project.

Audience Question

  • Q: Is there any plans for a document composer or editor?
  • A: Yes, that is planned. Plan to cover everything related to documents.

Audience Question

  • Q: does your viewer have the ability to touch or click contained words for event processing. ie. click a contained drawing number and lookup a database entry
  • A: There are mouse events that tell you where the click was in reference to the page, but doesn’t report what was clicked on. Full interactivity in the viewer is planned. Form filling and annotation support is coming.

Audience Question

  • Q: XE7 update1 is comming soon right? If so, does installing the update require reregister the product ?
  • A: You need a valid license and to be a registered user to install Update 1 when it is available.

Audience Question

  • Q: I am, just want to know if that require reregistering or not
  • A: Oh, does not require re-registering. I didn’t catch that the first time. Installing the update does not increment your registration count. If you do exceed your registratiosn though, you can submit for a registration limit increase.

Audience Question

  • Q: thanks
  • A: Sure.

Audience Question

  • Q: TurboPower Async pro Fax components where not upgraded :(
  • A: OK.


via: CodeRage 9 – Object Pascal Sessions.

Filed under: Appmethod, Delphi, Delphi XE7, Development, Software Development

by jpluimers at October 30, 2014 03:12 PM



NestedDataSets in ClientDataSets

A column of a ClientDataSet can contain a dataset, a tabular structure containing one or more columns and zero or more records. This presentation continues Cary Jensen’s CodeRage series on ClientDataSets by looking at this power field type.

Level: All
Cary Jensen – Jensen Data Systems, Inc.


Audience Question

  • Q: Would nested datasets akso be usable for defining new, lacking records in different tables
  • A: Yes. In the presentation I demonstrate creating nested dataset structures where no underlying database already exists

Audience Question

  • Q: Would nested datasets be something similar to a view made from lot of tables with ‘from table1 left join t on (table2.key=table1.key) left join …………
  • A: No. That would create a single table with values from two tables. A nested dataset is a dataset nested within a field of another dataset. With nested datasets you actually have two or more different tables

Audience Question

  • Q: Is there an easy way to exncrypt the data in a file that was written out using clientdataset or FDMemTable to for instance XML or JSON type file? Would one need to stream it and then encrypt/decrypt the stream upon writing/reading?
  • A: You got it right in you suggestion. To encrypt, you write from the CDS or FDMemTable to a stream, encrypt the stream, and then write that stream. You do the same in reverse to load the encrypted data

Audience Question

  • Q: ClientDataSet can be connected to 3rd party datasets using the provider component.Is FDMemtable limited to Firedac datasets ?
  • A: FDMemTables are currently designed for FireDAC datasets

Audience Question

  • Q: If I have a many to many relationship using an intersection table in between (Table A 1-n Table AB n-1 Table B). How do I write this out using the nested datasets?
  • A: To a file, call SaveToFile on the top-level CDS

Audience Question

  • Q: How am I going to get you to sign your new book !!! Having got you to sign your back back in London Delphi Deve Days !! LOL
  • A: We’ll just have to get you back to a Delphi Developer Days :)

Audience Question

  • Q: Nice presentation Carry
  • A: Thank you

Audience Question

Audience Question

  • Q: You show both the MidLevelCDS and the ThirdLevelCDS owned by the TopLevelCDS. Would/should the ThirdLevelCDS be owned by the MidLevelCDS instead?
  • A: The ownership is a detail, and has no effect on the master-detail linkage

Audience Question

  • Q: Audio: Still some artifacts, but clearer than it was
  • A: :-)

Audience Question

  • Q: I am routinely impressed with Cary’s knowledge and communication skills. Both contribute to my enthusiasm for Object Pascal! THANKS
  • A: :-)

Audience Question

  • Q: Great Presentation! I used this technique in a moblie application. It takes a little longer to load, initially, but once the data is loaded, no more round trips are required – which makes the app MUCH more robust.
  • A: :-)

Audience Question

  • Q: I was thinking about an a customer exists, but a certain order is lacking, could that lacking order record be inserted?
  • A: Not only can it be inserted into the detail table nested dataset, that record will be inserted by the TLD by a call to ApplyUpdates.

Audience Question

Audience Question

  • Q: An example on this compressing/encypting/saving and then loading/decrypting/uncompressing would be great.
  • A: Yes it would. Thanks.

Audience Question

  • Q: where do you find the latest version of the Turbo Power stuff
  • A: Source Forge

Audience Question

  • Q: Great Presentation! I used this technique in a moblie application. It takes a little longer to load, initially, but once the data is loaded, no more round trips are required – which makes the app MUCH more robust.
  • A:

Audience Question

  • Q: Is there a possibility in future that tclientdataset becames deprecated?
  • A: I doublt it, at least not anytime in the near future

Audience Question

  • Q: There are multiple flavors on SourceForge (…”New”)
  • A: Great.

More information on the special offers

Audience Question

Audience Question

  • Q: Confirmed – The link works
  • A: :-)

Audience Question

  • Q: Hope systools also would be part of the pacoage
  • A: That one might get some attention later. ;-)


via: CodeRage 9 – Object Pascal Sessions.

Filed under: Appmethod, Delphi, Delphi XE7, Development, Software Development

by jpluimers at October 30, 2014 03:09 PM



ClientDataSets and FDMemTables Compared

ClientDataSets are in-memory tables that have been in RAD Studio since Delphi 3, but there’s a new kid in town, the FireDAC FDMemTable. This presentation, by ClientDataSet expert Cary Jensen, compares and contrasts these in-memory table classes, providing you with guidance on which to use and when.

Level: All
Cary Jensen – Jensen Data Systems, Inc.

The Q&A log:

Welcome to CodeRage 9!

  • Q: Thanks for organizing this. Hi from The Netherlands
  • A: Hello and thanks for joining us!

Audience Question

  • Q: yes a great thing, greetings from Germany too!
  • A: You are welcome. Thanks for being here.

Audience Question

  • Q: Ill agreewith Neterhlands and Germany its 3 tuff days for you but very useful for us developers of all levels , hello and thanks from Swesen
  • A: Thanks and you are welcome!

Audience Question

  • Q: Good morning, David
  • A: You get Jim today. David is in the C++ track.

Audience Question

  • Q: Hello, I missed Allen Bauer’s session yesterday. Any links for demos and contact details for him, if possible?
  • A: Replays will be available for CodeRage sessions that you may have missed within 1-2 weeks of the conference conclusion on the CodeRage website.

Audience Question

  • Q: From Spain. Thanks you very much. Hello, smart thinks !
  • A: :-D You are welcome! Thanks for being here.

Audience Question

  • Q: Hi, Jim
  • A: Hi Cary!

Audience Question

  • Q: Ready with bells on. :)
  • A: Nice.

Audience Question

  • Q: Morning Chaps :)
  • A: Good morning!

Audience Question

  • Q: Thx for reviving the XE7 trial key
  • A: Certainly.

Audience Question

  • Q: Good morning. I’m from Indonesia.
  • A: Morning!

More information on the special offers

The virtual exhibit hall

Use the 10% off discount code “THINGS”

Audience Question

  • Q: Can one inmemory object contain updates to several tables in one, or do I need to update one table at a time.
  • A: Use nested datasets to include more than one table. CDS and FDMemTable differ. I discuss this later

Audience Question

  • Q: Are the CDS andf FD XML file formats compatible?
  • A: Not really

Audience Question

  • Q: If I want to use either in different threads, do I need to implement my own locking/protection, or are there any features that make this same and easy?
  • A: You need to implement your own synchronization. If the threads are created after the dataset is created, and the dataset is treated read-only, there may be no problems

Audience Question

  • Q: Better wording -> If I want to use either dataset in different threads, do I need to implement my own locking/protection, or are there any features that make this safe and easy?
  • A: Same answer as above. We can talk about this in Q&A

Audience Question

Audience Question

  • Q: did the CDS developers ever fix the performance problem encountered when adding lots of rows?
  • A: I don’t think so

Audience Question

  • Q: Are there plans to add support for TDatasetProviders to FDMemTable? It means otherwise a complete re-write of the existing DataSnap stack…
  • A: No. FDMemTables will likley support different mechanisms. FireDACJSONReflect is one of those

Audience Question

  • Q: You know what would be cool? A book dedicated to FDMemTables.
  • A: Yes. I wonder who might write that :)

Audience Question

  • Q: Thanks. My main use of CDS at the moment is as self-contained data containers inside a mobile app (ios and Android) which can take data via Datasnap and store locally to a file when offline. Biggest dataset is say 5000 records which includes some memo fields. Do you think there would be noticeable performance improvements using FDMemTables? (Sorry, tough question I know). Some filtering currently takes 2-3 seconds for example.
  • A: FDMemTables are often demonstratable faster than ClientDataSets, so there might be a performance enhancement

Audience Question

  • Q: If updating a tclientdataset based app to FDMemtable based, can I during update have both datasets involved on server or client?
  • A: Yes

Audience Question

  • Q: I cannot understand what Jensen is saying! :(
  • A: :-( It is difficult.

Audience Question

  • Q: Your new book does it contain information on FDMemTable or is it just on ClientDataSets?
  • A: It is exclusively ClientDataSet, and will be the last edition of that book since FDMemTable is gaining more of the features from ClientDataSet. It brings it up to XE7.

Audience Question

  • Q: The previous book was not electronically available. Will the new version be available in ebook format ex. through Amazon Kindle?
  • A: It will be Kindle

Audience Question

  • Q: I have very large applications using DataSnap and ClientDataSets in a Multi-Tier structure. Is It viable to change this structure to use FDMemTable?
  • A: It is, but wait for FDMemTable to expand.

Audience Question

  • Q: FDS binary output file size is 2x times larger than CDS binary output file size
  • A: thx

Audience Question

  • Q: I think you said you currently can’t move data from a CDS into a FDMem, is that right?
  • A: Not via the XML data property, or the XML file. You would need to read and pump the individual records. Maybe use the FD Batch move. They are different internally.

Audience Question

Audience Question

  • Q: How it’s working refrshing data on client side when using FDMemTable ? You show geting all DataSet and Aplying Updates but what with refreshing ? I need to get all DataSet again ?
  • A: You should be able to refresh the current record. Not sure. There are a lot of similarities between the two.

Audience Question

  • Q: Can we get discount on the new book .. if we bought the previous version :)
  • A: That isn’t possible through Amazon. The book will be reasonable priced.

Audience Question

Audience Question

  • Q: Really liked the first edition and refer to it a lot so looking forward to buying print and electronic copies of 2nd
  • A: :-D

Audience Question

  • Q: When making the video from this speech, is it possible to remaster the Q&A part by reanswering the questions so it is possible to understand what is said? (If Cary understand what he said)
  • A: We will

Audience Question

  • Q: DDD is great!
  • A: Thanks!

Audience Question

  • Q: I’ve been looking for a good solution to store complex configuration data specific to the working of the application. I’ve looked at XML files, JSON files, Client Datasets , IB2Go and would also now consider the FDMem tables. Can you suggest anyone over the others?
  • A: Using ClientDataSet or FDMemTable with nested datasets is a nice solution. FDMemTable supports JSON, which is more concise than XML


via: CodeRage 9 – Object Pascal Sessions.

Filed under: Appmethod, Delphi, Delphi XE7, Development, Software Development

by jpluimers at October 30, 2014 01:00 PM



A Dark Pattern is a type of user interface that appears to have been carefully crafted to trick users into doing things, such as buying insurance with their purchase or signing up for recurring bills.

We developers have a big responsibility. Martin Fowler and Erik Dörnenburg (both ThoughtWorks) did a great presentation about that at the GOTO Aarhus 2014 Conference.

A quote:

“The developer who wrote that code is every bit as responsible as the person who told them to do it. You have a choice. You have a responsibility to ensure that your users are well treated and to reject dark patterns,” says Fowler. “We have a whole profession of people writing software and doing enormous things to change the way we live in the world.”

Please watch the video: Our Responsibility to Defeat Mass Surveillance – Erik Dörnenburg and Martin Fowler – YouTube.



Filed under: .NET, Delphi, Development, Software Development, Usability, User Experience

by jpluimers at October 30, 2014 11:00 AM

October 29, 2014

twm’s blog

Avira Antivirus E-Mail “security”

The current Avira Antivirus has got a module it calls “Internet scurity” which in turn has an option for e-mail security.

What it does is capturing all connections to POP3, IMAP and SMTP servers and scanning them for viruses. That sounds good until you find, that your e-mail client stopped working even though you haven’t changed anything in it’s configuration.

Why is that? It’s because of this e-mail “security” feature. If you are using encrypted transport (START TLS or SSL/TLS), Avira cannot read the traffic and blocks it! This is so stupid, there must be an award for it somewhere.

To work around this, you can of course

  • disable the e-mail security feature
  • disable transport encryption

The first has the drawback that Avira now complains that your computer is not secure. The second has the drawback that your e-mails can be read by everybody who can access your connection to the server. So both options aren’t really solutions. If Avira forces you to do that (e.g. if the following doesn’t work for you because your mail server does not have alternative ports for encrypted connections), your computer is actually less secure than without Avira e-mail “security”.

Then there is the third option: Don’t use the default SMTP (25), POP3 (110) and IMAP (143) ports but use different ones, e.g. the ones that are reserved for encrypted transports:

  • SMTPS: 465
  • POP3S: 995
  • IMAPS: 993

Unfortunately that means your mail servers must support these protocols / ports. E.g. if you are using postfix you have to change / uncomment the following lines in the /etc/postfix/ file:

smtps     inet  n       -       -       -       -       smtpd
#  -o syslog_name=postfix/smtps
  -o smtpd_tls_wrappermode=yes
  -o smtpd_sasl_auth_enable=yes

And, or course, restart postfix.

The same applies to your POP3 or IMAP server.

If you can’t do that and your e-mail provider doesn’t support this, tough luck!

In addition, you must change the configuration in your e-mail client. In Thunderbird that’s pretty much straight forward:

WARNING: I will not fix your computer if you break it even if you followed my instructions. It’s your own responsibility. Making a mistake in the Thunderbird configuration will prevent it from receiving and/or sending e-mails.

  • Open the account settings dialog.
  • Select “Server Settings”.
  • Under Connection Security, select SSL/TLS (preferred) or STARTTLS, depending on what your server supports.
  • The port number will change automatically. If it doesn’t or your server does not use the default ports for encrypted transport, change the port number.
  • Select “Outgoing Server (SMTP)” (it’s down, below “Local Folders”).
  • Edit the entry you want to change (usually there is only one).
  • Change Connection Security to SSL/TLS (preferred) or STARTTLS, depending on what your server supports.
  • The port number will change automatically. If it doesn’t or your server does not use the default ports for encrypted transport, change the port number.

Now test it and have fun.

by dummzeuch at October 29, 2014 04:59 PM

The Podcast at

Voice Enable Your Android Apps

During CodeRage 9 I revisited adding voice support to Android apps. There are some updates from my previous skill sprint coverage on the topic and my original post on launching Google Glass apps via Voice.

You can download the Samples and Components on GitHub. It covers voice recognition, text to speech and launching apps on Google glass with your voice. The examples also cover Android Wear.

Voice Launching Google Glass Apps

  • Add a Voice Trigger XML file:
  • Modify the Android Manifest Template:
    • Add an Intent Filter
      • <action android:name=””/>
  • Add Meta Data for Filter
    • <meta-data android:name=””
             android:resource=”@xml/my_voice_trigger” />

Custom Glass Voice Trigger

  • Change XML to from Command to Keyword.
  • Use arbitrary text for voice trigger.
  • Use the Development permission:
    • <uses-permission
    • Added to android manifest template
  • Not allowed for app store distribution
    • Usable for in-house or ad-hoc use

Additional Prompts on Google Glass

  • Collect additional Voice recognition input when app is launched.
    • Add an Input Prompt to the Voice Trigger XML
      • <?xml version=”1.0″ encoding=”UTF-8″?>
      • <trigger command=”TAKE_A_NOTE”>
      •     <input prompt=”What shall I say?” />
      • </trigger>
  • In FormCreate get speech guesses from Intent Extras
    • SharedActivity.getIntent.getExtras. getStringArrayList(TJRecognizerIntent.JavaClass.EXTRA_RESULTS);

Voice Recognition on AndroidAndroid/Google - Speak Now

  • Prompts user for voice input
  • Returns up to 5 “guesses”
  • Works offline too
    • (only returns 1 guess)
  • Reusable component for download.
  • Requires RECORD_AUDIO & INTERNET permissions.
  • Sends audio to Google’s servers.
  • Uses context to select words.
  • Pronounce punctuation (period, comma, etc.)
  • Works on Android phones & tablets
  • Works on Google Glass
  • Works on Android Wear
  • Doesn’t work on iOS (no exposed API)

Using TSpeechRecognition Component

  • Properties
    • Language: en-US
    • Prompt: Speak now
    • AlwaysGuesses: True
  • Methods
    • Listen
    • ListenFor
  • Events
    • OnRecognition
    • OnRecognitionEx
    • OnCommand

Text-To-Speech on Android

  • Converts Text to spoken word.
  • Reusable component based on Jeff Overcash’s translation.
  • Code shows example of handling Java Listener events.
  • Works on Android phones & tablets
  • Works on Google Glass
  • Doesn’t work on Android Wear (no speaker)
  • iOS Support is possible . . . . (needs implementation)

Using TAndroidTTS Component (component name may change)

  • Just one procedure: Speak

A Note About iOS

  • iOS does not expose voice recognition API
    • (Need to use 3rd party)
  • iOS 7 supports Text to Speech API
    • AVSpeechSynthesizer
    • Just haven’t implemented in component yet

Google Glass Voice Trigger Sample

The replay video will be available here later.

Download the XE7 Trial today and check out the special offers.

by Jim McKeeth at October 29, 2014 01:06 AM

October 28, 2014

The Podcast at

Fire UI and the Multi-Device Designer

During CodeRage 9 I had a session on Fire UI and the Multi-Device Designer. You can also check out my previous post on creating a custom FireUI view for the Moto 360.

Fire UI is made up of three parts:

  1. Behavior Services – Runtime & design time platform design information
  2. Multi-Device Designer – Unified project – Tweak UI for platforms
  3. TMultiView Component – Adaptive layout

Behavior Services at Design Time

  • Examples:
    • TTabControl.TabPosition
      • Bottom on iOS, top otherwise
    • Font.Size & Font.Family
    • Many controls have Size.PlatformDefault = True
    • TMultiView mode

Behavior Services at Runtime

  • TBehaviorServices class in FMX.BehaviorManager.pas
  • IDeviceBehavior defines
    • GetDeviceClass: TDeviceInfo.TDeviceClass;
    • GetOSPlatform: TOSPlatform; // Windows, OSX, iOS, Android
    • GetDisplayMetrics: TDeviceDisplayMetrics;
  • IFontBehavior defines
    • GetDefaultFontFamily & GetDefaultFontSize

OS Specific example

  DeviceBehavior: IDeviceBehavior;
  if TBehaviorServices.Current.SupportsBehaviorService(?
    IDeviceBehavior, DeviceBehavior, Self) and
    (DeviceBehavior.GetOSPlatform = TOSPlatform.iOS) then
    // behavior specific to iOS

Display metrics example

  DisplayMetrics: TDeviceDisplayMetrics;
begin                        // self is a form in this case
  DisplayMetrics := DeviceBehavior.GetDisplayMetrics(Self);
  if DisplayMetrics.AspectRatio > x then
    // AspectRatio specific behavior
TDeviceDisplayMetrics = record
    PhysicalScreenSize: TSize;
    LogicalScreenSize: TSize;
    AspectRatio: Single;
    PixelsPerInch: Integer;
    ScreenScale: Single;
    FontScale: Single;

More Information

Check back later and I’ll have the video replay available too.

Download the XE7 Trial today and check out the special offers.

by Jim McKeeth at October 28, 2014 04:18 PM

Firebird News

Node C++ driver node-firebird-libfbclient updated to version v0.0.11

Node C++ Module for Firebird is updated in git repository and is already pushed to npm It can be compiled now with node v10.x  , There is work in progress for node v11.x nan is now a dependency If you want to install it from git sudo npm install -g  xdenser/node-firebird-libfbclient or from npm with […]

by mariuz at October 28, 2014 02:57 PM

Firebird release strategy for 2015-2016 #fbconf14

We start to publish presentations from Firebird Conference 2014. The first presentation is “Firebird release strategy in 2015-2016“, by Dmitry Yemanov, core Firebird architect  

by mariuz at October 28, 2014 02:25 PM

Castle Game Engine news

Reshared post from Michalis Kamburelis:

Original Post from Michalis Kamburelis:

Frogger 3D for Android and Linux :) My 0h gamejam game, slightly extended --- with shadows, better 3D, touch support, infinite cylinders, water etc. Because I can :) Download from

Source code on github:

October 28, 2014 04:03 AM

October 27, 2014

Firebird News

Mark Rotteveel Firebird Conference presentations + source code #fbconf14

Here are his  Firebird Conference Jaybird and Jooq presentations + source code:   1: 2: 3:  

by mariuz at October 27, 2014 07:57 AM

October 24, 2014

Firebird News

#fbconf14 is the official twitter stream for Firebird Conference 2014

You can watch the twitter stream from Firebird Conference 2014 : #fbconf14

by mariuz at October 24, 2014 02:51 PM

October 23, 2014

twm’s blog

Fighting Secure Boot

I have bought an Acer Extensa notebook after reading the under 300 Euros notebooks test in the latest c’t magazine where it came up as the winner regarding battery life and the rest wasn’t too bad either. I chose the 4 GB model so it won’t thrash the hd all the time. The Extensa comes preinstalled with Windows 8.1 and – as so many computers nowadays comes without an install medium and also without a user’s manual. (The link given in the short setup guide for downloading the manual leads to a non-functional site. Not very user friendly in my book.)

Now, what is the first thing you do, when you get a new computer which comes pre-installed with an operating system but does not come with an install medium? I for one, make a backup, preferably an image backup of the whole hard disk using Clonezilla. Since this is my image backup tool of choice I carry it with me on a USB stick almost all the time (Hey, I work in IT, so it’s pretty much normal to carry USB sticks and other stuff. ;-) ). So I plugged that USB stick into the notbook and booted it up. It went straight into the Windows 8.1 setup screen. :-(

So I tried to get a boot menu. Perusing Google told me that Acer notebooks use F12 for the boot menu. Unfortunately this didn’t work. Windows 8.1 setup again. :-(

Next, I tried to get into the BIOS, or whatever the UEFI stuff nowadays calls this tool. The usual DEL key didn’t work but after several reboots and key presses I ended up in some windows boot menu that allowed me to boot from an USB stick. Only, it didn’t. It told me there was a secure boot failure and stopped.

Turning the computer off and on again, this time I apparently got the BIOS setup key right: F2 (I didn’t work the first several times I tried it, why?) I got something called “Insydeh” which looked like a BIOS of old. And there it was: An option to turn off “secure boot”, only it was disabled. I could only switch to BIOS mode which I didn’t want to. WTF?

Google to the rescue again: To turn off secure boot, you first must set a supervisor password. So I did that, came back to the secure boot screen and lo and behold, the option to turn it off was enabled now. After turning it off, I could clear the supervisor password and the option was still enabled. Another setting I changed was the F12 boot menu. It was disabled by default so I enabled it.

Save and reboot, press F12 and – voila – a boot menu which finally allowed me to boot clonezilla from my USB stick. The backup is running now.

Praise Microsoft for requiring PC manufacturers to have an option to turn off secure boot if they want to be Windows 8 compliant (I wonder whether that will still be a requirement for Windows 10, though.). But curse Microsoft and the bloody PC manufacturers to come up with the pretty much useless secure boot feature at all. It’s my computer, I paid for it, so it should be my choice to install whatever operating system I want on it!

by dummzeuch at October 23, 2014 06:26 PM

The Wiert Corner - irregular stream of stuff

October 22, 2014

The Wiert Corner - irregular stream of stuff


It is always nice to see one of the compiler engineers write down how something was implemented.

In this case, Barry Kelly explains in comp.compilers on Implementing Closures in Delphi 2009. The post is about 4.5 years old, but still very relevant.

About 9 months earlier, he participated in a Reddit thread about a similar topic. Worth reading too!


via: Implementing Closures – Google Groups.

Filed under: Delphi, Delphi 2009, Delphi 2010, Delphi x64, Delphi XE, Delphi XE2, Delphi XE3, Delphi XE4, Delphi XE5, Delphi XE6, Delphi XE7, Development, Software Development

by jpluimers at October 22, 2014 05:00 AM

October 21, 2014

Firebird News

Firebird 3 Launch Campaign!

Firebird 3 is on the fast track to be released very soon, and all FirebirdSQL developers should help Firebird Project to release v 3.0 as soon as possible. You can help Firebird in the following areas: Beta-testers! Firebird 3 must be thoroughly tested with real-life databases and applications – with your applications and databases! Download […]

by mariuz at October 21, 2014 01:08 PM

Firebird Conference 2014 schedule is available #fbconf2014

Firebird Conference 2014 schedule is available. Only few days left! Hurry up, registration is still open!

by mariuz at October 21, 2014 08:07 AM

The Wiert Corner - irregular stream of stuff


Every once in a while you see a question with some great code in the answers.

This is such a time: image – How to make a water effect on TImage or anything? – Stack Overflow.


Filed under: Delphi, Development, Software Development

by jpluimers at October 21, 2014 05:00 AM

October 20, 2014

הבייט הלבן

העז המנופחת של Microchip

מי שמוריד את סביבת הפיתוח הרשמית והחינמית MPLAB X, של חברת Microchip, מקבל איתה בין השאר את הקומפיילר XC8 בגרסה שמבצעת (כך מספרים לנו) רק אופטימיזציות בסיסיות. כדי להפיק קוד יעיל באמת, הלקוחות נדרשים לקנות גרסה משופרת. עד כאן סביר ולגיטימי, נכון? אבל איזה מעשה מפוקפק עושה Microchip כאשר ההבדל בביצועים בין הגרסה הרגילה למשופרת […]

by עידו גנדל at October 20, 2014 10:31 PM

Daniel Magin's Logfile

PAServer Manager and Mac OSX Yosemite and Delphi XE7

After updating Mac's to Yosemite there was no way to start a PAServer over the PAServerManager.

Solution go to Spotlight an Type in "PAServer 15". Then you start direct the PAServer without the PAServerManager. BTW i ask me really why the PAServerManager will not save the settings after reboot.

Bildschirmfoto 2014-10-20 um 17.33.44

You can also start PAServer 15 from Terminal Session with:

  1. /Applications/PAServer\

On one of my Mac's i get after starting the PAServer  with Yosemite and the brand new Xcode a codesign error on Deploy Process.

Solution send a export before starting PAServer

  1. export CODESIGN_ALLOCATE="/Applications/"
  2. /Applications/PAServer\

Bildschirmfoto 2014-10-20 um 17.32.18

by admin at October 20, 2014 03:35 PM

October 19, 2014

Firebird News

Video: How to use the Firebird Trace API and FB TraceManager in high load scenarios

The following video discusses best practices for using the Firebird Trace API and FB TraceManager in high load scenarios. CLICK HERE to watch the ~24 min video. Enjoy!

by tsteinmaurer at October 19, 2014 12:19 PM

October 17, 2014

Castle Game Engine news

Reshared post from Michalis Kamburelis:

New game done using our engine :)

Original Post from Michalis Kamburelis:

I'm presenting a small game called "Hotel 'Nuclear'" that I did during last weekend (two days, one game, zero sleep) TSG compo (gamejam).  Of course using my Castle Game Engine :) You're welcome to download it from , developers are also welcome to checkout source code (to you also need "Castle Game Engine" from SVN, see ).
Short post-mortem (I actually have some useful conclusions at the end :) follows. I decided to write it down, while it's still fresh in my mind :)


This is not my perfect creation --- although I am proud of what I achieved, there was simply not enough time to really do what I imagined. I finally picked a project that cannot be finished by 1 person in 2 days :) Which is Ok for me, since I still achieved a lot.

Actually I feel that this is my largest compo game (a lot of programming stuff, a lot of graphic stuff...). To be honest, after every compo, I think "this was the largest work I managed to do during 2 days". Which is very cool. Even if part of this impression is just me being dead-tired, I'm also pretty sure that I'm getting awesome-and-more-awesome with every compo :) The engine (as most of you know, "Castle Game Engine" is my own beloved open-source game engine) also grows because of compo games. Even though I explicitly want to work on a specific game, not on the engine, during the compo. But often some good engine-wide work happens by the way (and, while game-specific code is sometimes quick & hacky, the engine code remains clean & perfect :). And my crazy Blender/GIMP skills also get nicely refreshed every time :)


- The "core" mechanics work (ghost captures human/alien, changes into them, opens doors, dies in incorrect room, gets keys, opens locked doors, there are hints on doors about keys, somewhat resembling logical puzzles). I think I had a good work plan for programming-related tasks.

- The core graphics are in place. Corridor, room, animations. But look bad, more about this later.

- The game is playable. But it was playable too late, when the Sunday was ending, and there was no time to tweak it.

- Technically were Ok: game works fast, on standalone and Android. "Castle Game Engine" rules! :)

- We have random hotel floors, which was my core "technical" goal. Success :)

- As usual, the built-in "WalkAttack" AI available in Castle Game Engine was a great time-saver. Even when not perfect, it gives you an extremely quick (nearly 0 code) working creature AI in a free 3D worl.


With compo games, I usually have

1. some "gameplay/graphics/feeling" goal (roguelike forest - "Orcs and Volcanoes", fear in 3D - "Darkest Before the Dawn", beautiful - "Little Things", dangerous world - "Mountains Of Fire") and

2. some "technical" goal (level editor and 2D mixed with 3D - "Orcs and Volcanoes", Android - "Darkest Before the Dawn", go crazy with shaders and screen effects - "Little Things", split screen and controls - "Mountains Of Fire").

I found that this works for me. I have to visualize that "this particular game will be great (mostly gameplay/graphics/feeling goal)", but I also have to visualize "this work will make the engine better (mostly technical goal)".

This time the "gameplay/graphics/feeling" goal was "weird hotel in space with logical puzzles". I was thinking about many things, including "Doctor Who" "God Complex" episode.

The technical goal was "random generation of 3D stuff".


- Graphically, a lot of stuff is very unfinished (1. lighting is bad --- bleak on corridor, nonsense spheres in rooms, while the purpose was to showcase small local point lights in somewhat dark setting, 2. animations are just tests --- knight and archer from representing human and martian..., 3. room interior lacks textures... although, AD3, it was a good decision to leave it as is).

I feel that I could do these things, but there was no time.

- Gameplay: while it works, it needs more stuff to make it really interesting. E.g. special ability of human/aliens. Better AI (they cannot leave the room now! Bad, I planned to use our waypoints/sectors for it). Maybe sometimes you can be killed (e.g. martians hunt humans?), maybe sometimes you can shoot (again, martians shoot humans? :), maybe sometimes keycards are in different places... I had lots of ideas to experiment and make the gameplay more varying. No time to implement and test them.

- More hints on the doors were planned, to make it more a logical puzzle, interesting and playable with really large floors. I managed to implement most important ones ("the key xxx is here", "the hint on the room to the left IS A LIE" etc.). More were planned.

FUTURE AND THOUGHTS (aka: "notes to future self") :

1. Make the graphics crude, but focus on showcasing the main thing first.

For example, with "Mountains Of Fire", the "focus" (core idea) of graphic was "black vs red colors". With "Little Things", it was shaders and painting-like look. For this game, I should have said to myself "the core look depends on bright lamps in a long, dark corridor". Good: I did make the corridor perspective (all those views on a long corridor work :), bad: I did not set up nice lighting.

Instead of playing around with texturing etc, I should have focused on lighting, as the lighting was my core graphical vision here.

CONCLUSION 1: decide what is the main feature of your graphical look, and make it happen soon, this rules over everything else.

Do not tweak textures. Do not tweak 3D meshes. Do not make any animations, there is really no time for it (for me at least) during the compo. Spend more time on choosing (and brutally adjusting) downloaded stuff from and .

2. Gameplay must be playable much sooner. With previous compo games, I spent Sunday evenings designing specific levels, and gameplay mechanics was somewhat ready (or at least "during testing"). This time, there was no level design. There was a lot more coding and graphical stuff instead. And the gameplay was finished very late (near the end of Sunday), which prevented from tweaking/rethinking it.

I think that the idea "Sunday noon is the deadline for working gameplay" is a good idea.

But how could I have applied it here? If I would just force myself on Sunday noon, I could have resigned from random hotel generation, and instead make 2-4 pre-staged hotel floors in Blender. Looking back, it would be the right choice.

Or I could invent a different gameplay, playing around only with room interiors. Which means "change your whole idea". Problem: this happens on Sunday morning, when you're already getting sleepy, and thinking is difficult :) Looking back, having a backup plan, with only half of stuff ready, would be nice... But that's not really doable for me, to have a backup 50% plan and still commit 100% to the original plan... So, solution: at Sunday 12:00 drink lots of cofee, and invent new gameplay if necessary!

CONCLUSION 2: gameplay must be ready on Sunday noon. If not: cut down on technical stuff, make smart workarounds in graphics. "Short and playable" is your goal on compo, not "long and boring". Also, drink coffee at Sunday noon and if necessary, just change your whole gameplay idea.


As (almost) always, the graphics in this game use various assets from and . Thanks go to many contributors on these sites. Details are in AUTHORS.txt files in sources.

October 17, 2014 10:44 PM

Firebird News

More mini-interviews with speakers at Firebird Conference 2014

More mini-interviews with speakers at Firebird Conference:Jiri Cincura, Roman Simakov, Pavel Cizar and Jonathan Neve

by mariuz at October 17, 2014 12:56 PM

October 16, 2014

Firebird News

Good news for .Net Provider : Dapper – a simple object mapper for .Net can be used with Firebird

Good news  for Firebird .NET Data Provider: a issue in the Dapper github repository seems to be fixed    

by mariuz at October 16, 2014 03:24 PM

Database Workbench 5.0.4 released

Upscene Productions is proud to announce the availability of the next release of the popular multi-DBMS development tool: ” Database Workbench 5.0.4 “ This release fixes bugs found by customers and a fix for using Database Workbench under Wine. “There is so much new in Database Workbench 5, I don’t know where to start”, says […]

by Martijn Tonies at October 16, 2014 09:44 AM

October 15, 2014

DWS Web Server update

A new version 2014.10.15 of the DWS Web Server is available. This version contains a variety of improvements and fixes, along with a new sample for JS libraries. Here is the download link for the installer: DWSWebServer 2014.10.15 (1514 kB) And here is the list of changes: added support for .p2js libraries and marking functions with “export”…

by Eric Grange at October 15, 2014 05:00 PM

Firebird News

The Lazarus team is glad to announce the release of Lazarus 1.2.6

The Lazarus team is glad to announce the release of Lazarus 1.2.6. This release was built with fpc 2.6.4. Here is the list of changes for Lazarus and Free Pascal:

by mariuz at October 15, 2014 04:36 PM

Release candidate 2 of .Net Provider for OleDb

We are pleased to announce the second release candidate of our .NET Data Provider for interaction with Firebird and Interbase via IBProvider. By now, we have implemented all the functionality of System.Data.OleDb. If you want to transfer your .NET projects for FB/IB to the new level of functionality and quality, we recommend you to start […]

by Andrew Merkulov at October 15, 2014 01:48 PM

Node Firebird Pure Java Script driver 0.2.0 is released with many features and fixes

New version v0.2.0 supports added auto-reconnect added sequentially selects events (attach, detach, row, result, transaction, commit, rollback, error, etc.) performance improvements supports inserting/updating buffers and streams reading blobs (sequentially) pooling database.detach() waits for last command better unit-test best of use with total.js – web application framework for node.js Many thanks to Peter Širka for his contributions […]

by mariuz at October 15, 2014 06:50 AM

The Wiert Corner - irregular stream of stuff


The Delphi MESSAGE directive is a very powerful one, you can generate compiler hints, warnings and errors with it, even fatal ones that abort compilation.
The compiler will return error codes H1054 (hint), W1054 (warning), E1054 (error) or F1054 (fatal error), which in the documentation are known under the catch-all x1054.

You need to take a bit of care with message directives, especially with the quotes. For instance

{$Message Error 'Not implemented'}

gives you the error below, but continues compiling:

[DCC Error] E1054 Not implemented

However, if you forget the single quotes

{$Message Error Not implemented}

it gives you error E1030  (not x1054), which is a bit confusing as it is a catch-all for invalid directives:

[DCC Error] E1030 Invalid compiler directive: 'message'

Here is a full example of all the message directives and compiler reactions you can get:

program Message_Directive;


{$R *.res}

  {$MESSAGE 'Boo!'}
  {$Message Hint 'Feed the cats'}
  {$messaGe Warn 'Looks like rain.'}
  {$Message Error 'Not implemented'}
  {$Message Fatal 'Bang.  Yer dead.'}
[DCC Hint] Message_Directive.dpr(8): H1054 Boo!
[DCC Hint] Message_Directive.dpr(9): H1054 Feed the cats
[DCC Warning] Message_Directive.dpr(10): W1054 Looks like rain.
[DCC Error] Message_Directive.dpr(11): E1054 Not implemented
[DCC Fatal Error] Message_Directive.dpr(12): F1054 Bang.  Yer dead.


via: MESSAGE directive (Delphi) – RAD Studio.

PS: for a full list of Delphi hint/warning/error compiler messages, see Marc Durdin’s excellent post  Delphi XE2′s Hidden Hints and Warnings.

Filed under: Delphi, Delphi 2005, Delphi 2006, Delphi 2007, Delphi 2009, Delphi 2010, Delphi XE, Delphi XE2, Delphi XE3, Delphi XE4, Delphi XE5, Delphi XE6, Delphi XE7, Development, Software Development

by jpluimers at October 15, 2014 05:00 AM

October 14, 2014

Lazarus Team Anouncements

Lazarus 1.2.6 Release

The Lazarus team is glad to announce the release of Lazarus 1.2.6.

This release was built with fpc 2.6.4.

Here is the list of changes for Lazarus and Free Pascal:

October 14, 2014 03:18 PM

Firebird News

Firebird 3 Beta 1 tagged

The source code of Firebird 3.0 Beta 1 is now tagged, meaning that we can expect the beta 1 release to be available very soon.

by Cantu at October 14, 2014 11:45 AM

The Wiert Corner - irregular stream of stuff


Delphi and 3rd party tools keep some of the settings in your %AppData% directory. Much more convenient than the registry as they are easier to read and modify when needed (also easier to damage <g>). We’ll start with an overview where various versions of Delphi store their configuration files, then show how the Favourites on the Welcome Page are stored, then end with an overview of BDS, Company Names and Product Names.

Configuration files

Depending on the Delphi version, the files are under one of these directories:

  • %AppData%\%CompanyName%\BDS\#.0 %AppData%\%CompanyName%\RadStudio\#.0
  • %AllUsersProfile%\Application Data\%CompanyName%\RadStudio\#.0

%AppData% is for user specific settings; %AllUsersProfile% for system global settings. BDS stands for Borland Developer Studio, the official name for the (then new) Gailileo IDE foundation that was the successor of the old IDE architecture used from Delphi until 7. In practice, I’ve never seen any file stored under the RadStudio directory within %AppData%.

Registry paths.

Note the registry key paths used for configuring Delphi are constructed in a way similar to the directory names:

  • HKEY_CURRENT_USER\Software\%CompanyName%\BDS\#.0
  • HKEY_LOCAL_MACHINE\Software\%CompanyName%\BDS\#.0

Note the registry only uses BDS, not RadStudio. Both %CompanyName% and # depend on the BDS versions. So further below are two lists: one mapping the BDS version to CompanyName, the other to Delphi version. But first about the files in the Delphi settings directory, so we can start looking at how favourites are stored.

BTW: Though not covered any further here, Delphi 2-7 had different registry roots as mentioned in a SO comment by Remy Lebeau:

  • HKEY_CURRENT_USER\Software\Borland\Delphi\#.0

  • HKEY_LOCAL_MACHINE\Software\Borland\Delphi\#.0

Delphi settings directory files

These are the files you usually have in the directory %AppData%\%CompanyName%\BDS\#.0:

myFavorites.xml: the Favourites in your Welcome page

Back to the Favourites that you can organize in your Welcome page. These are stored in myFavorites.xml which has a remarkably simple XSD structure (both links are to Pastebin as WordPress regularly screws up XML). Normally the XML is on one line, but with an online tool like Free Online XML Formatter – you can put everything into a human-readable form. Delphi can work with both. This allowed me to move my source directory tree from C:\Develop to another directory in a small search/replace manner.

CompanyName mapping

  • CompanyName=Borland (from BDS 1 until BDS 5)
  • CompanyName=CodeGear (from BDS 6 until BDS 7)
  • CompanyName=Embarcadero (BDS 8 and up)

You see that CodeGear only lived for a short period of time. There is quite a bit confusion on the internet about this, just look at these searches to get a feel for that:

BDS number to product version mapping

I’ve included the table below as the data is not in the table I referenced from Found a table with Delphi Conditional defines over the Delphi versions/compiler platforms/bitness.

The # depends on the BDS/Galileo version number which started with Borland Development Studio 1.0 a.k.a. C# Builder 1.0.

For each product version, I noted which products were added/removed compared to the previous one.

  1. C# Builder (contained only C# Builder)
  2. Delphi 8 (added Delphi .net)
  3. Delphi 2005 (added Delphi win32)
  4. Delphi 2006 (added C++ Builder)
  5. Delphi 2007
  6. Delphi 2009
  7. Delphi 2010
  8. Delphi XE
  9. Delphi XE2 (added Delphi win64)
  10. Delphi XE3 (added C++ Builder win64, OS X x86 and iOS x86/arm through FreePascal)
  11. Delphi XE4 (replaced FreePascal with native Delphi compiler for iOS x86/arm)
  12. Delphi XE5 (added Android ARMv7)

I verified most of these from either my own Delphi / C# Builder installations or from the uDelphiVersions unit in WMI Delphi Code Creator.

And at the time of writing, I’m guessing BDS 12, and wondering if BDS 13 will be skipped like Delphi 13, jokingly or not like mentioned in The Oracle at Delphi » What happened to version 13?.


Filed under: Delphi, Delphi 2005, Delphi 2006, Delphi 2007, Delphi 2009, Delphi 2010, Delphi 8, Delphi XE, Delphi XE2, Delphi XE3, Delphi XE4, Development, History, Software Development

by jpluimers at October 14, 2014 05:00 AM

October 13, 2014

DWS WebServer with JavaScript CodeGen

The pre-compiled 2014.10.13 version of the DWScript WebServer is now available! This version includes the Pascal to JavaScript CodeGen! Here is the download link for the installer: DWSWebServer 2014.10.13 (1541 kB) This version also includes all fixes and improvements in DWScript, but the main attraction is the Pascal to JavaScript compiler, which bundles a limited version of SmartMobile…

by Eric Grange at October 13, 2014 01:30 PM

Firebird News

Compiling IBASE sql driver for Qt 5.3 on openSUSE 13.1

For this howto you will need to have firebird development package already installed on the system and also Qt 5.3.

by mariuz at October 13, 2014 07:36 AM

XE Plus Pack – Free License details

Grab your free license details for Delphi XE Plus Pack.


License Details

Name: XE Plus Pack - Free License
Key: 02B537-8A808F-EFE83C-00E6EE-8BA946-3076F6-052F5F-CFC103-022F85-A28C71-006084


How to register

Download the trial version:

Use the Help | Register XE{x} Plus Pack… menu item to register.


Further install and help is available from or email,


Important info

  1. Only works for Delphi XE version.


by JED at October 13, 2014 06:20 AM

October 10, 2014

The road to Delphi

VCL Styles Utils – Now supports the TTaskDialog component

I’m very pleased to introduce a very exciting new feature to the VCL Styles Utils project. This is the support for style the TTaskDialog component and all the TaskDialog based Message dialogs. This control available since RAD Studio 2007 is a wrapper for the Task Dialogs introduced in Windows Vista and allows to create very rich and flexible dialogs.

Take a look to some sample dialogs.

2014-10-09 09_48_43-VCL Styles Utils - TTaskDialogs Demo

2014-10-09 09_41_40-VCL Styles Utils - TTaskDialogs Demo

2014-10-09 09_42_31-Greenshot

2014-10-09 09_47_41-VCL Styles Utils - TTaskDialogs Demo

2014-10-09 09_47_52-VCL Styles Utils - TTaskDialogs Demo

2014-10-09 09_48_07-VCL Styles Utils - TTaskDialogs Demo

2014-10-09 09_48_19-VCL Styles Utils - TTaskDialogs Demo

2014-10-09 09_48_31-VCL Styles Utils - TTaskDialogs Demo

And now enabling the VCL Styles and just adding the Vcl.Styles.Hooks unit to your project…..

2014-10-09 09_57_33-VCL Styles Utils - TTaskDialogs Demo

2014-10-09 09_58_01-VCL Styles Utils - TTaskDialogs Demo

2014-10-09 09_58_28-VCL Styles Utils - TTaskDialogs Demo

2014-10-09 09_58_55-VCL Styles Utils - TTaskDialogs Demo

2014-10-09 09_52_55-VCL Styles Utils - TTaskDialogs Demo

2014-10-09 09_54_40-VCL Styles Utils - TTaskDialogs Demo

2014-10-09 09_55_11-VCL Styles Utils - TTaskDialogs Demo

2014-10-09 09_55_40-VCL Styles Utils - TTaskDialogs Demo

2014-10-09 09_56_04-VCL Styles Utils - TTaskDialogs Demo

2014-10-09 09_56_42-VCL Styles Utils - TTaskDialogs Demo

You can download a sample application from the project repository.
Also a compiled demo is available here.

If you found any bug please use the issue page of the project.

For a quick tutorial of how use the TTaskDialog component check this great Inofficial TTaskDialog Documentation.


by Rodrigo at October 10, 2014 12:54 AM

October 09, 2014

Firebird News

ANN: CopyCat Developer 3.07.0

Microtec is pleased to announce a new release of our database replication engine, CopyCat Developer ! CopyCat Developer is a set of Delphi / C++Builder components providing customizable replication for Firebird, Interbase, Microsoft SQL Server, MySQL, NexusDB, SQLite, PostgreSQL and Oracle, including heteogenous replication between different database types. Have a look at our site for […]

by jonneve at October 09, 2014 09:19 PM

twm’s blog

mounting a Samba share

The Linux mount command can also access Samba (Windows) shares, but in contrast to the smbclient command it does not do a Netbios based lookup for machine names. So while

smbclient //server/share

will work, the corresponding

mount -t cifs //server/share /mnt/point

will tell you that it can’t resolve the host name (unless you add the host to your hosts file or it can be looked up via dns).

This StackExchange answer pointed me in the right direction:

There is a command for actually doing that lookup. It’s called nmblookup.
It returns the IP address of the server like this:

nmblookup server server00>

While this is fine for manually looking it up, if you want to mount a share multiple times or in shell script, this won’t do because you need the IP address only, not the suffix after it.

It gets even worse if the machine in question has more than one IP address:

nmblookup server2 server200> server200>

Bash to the rescue (I found that solution via this StackOverflow question and this article.)

shift  # Remove machine name from argument list

shift  # Remove share name from argument list

# nmblookup the machine
RES=$(nmblookup $MACHINE)
#echo "RES=\""${RES}"\""

# remove everything but the ip address
# note that this will not return anything meaningful
# if nmblookup returns an error (e.g. cannot find the machine)
#echo "IP=\""${IP}"\""

# Mount smbclient share (passing any arguments on to smbmount
mount -t cifs -r //${IP}/${SHARE} "$@"

Put this code into a file, e.g.


and call it like

mount-win-share server share /mnt/point

If you add additional parameters or options, they will be passed on to mount.

by dummzeuch at October 09, 2014 04:19 PM

October 08, 2014

twm’s blog

Creating a new RAID 5

Another reminder to myself, so I don’t forget it again.

Warning: Use this on your own risk! You might lose all the data stored on any of the hard disk drives if you make a mistake!

To create a new raid, all the disks must be partitioned first.

To actually create the RAID we need the tool mdadm which is not installed (on Ubuntu Server) by default.

apt-get install mdadm

This will also install a few dependencies, in particular it will install a mail transfer agent (MTA, postfix in my case). This MTA needs to be configured so it can send e-mails to the administrator (root).

Creating the raid is as easy as typing:

mdadm --create /dev/md0 --level=5 --raid-devices=4 /dev/sdb1 /dev/sdc1 /dev/sdd1 /dev/sde1

Mdadm might detect that the disks have already been used in a different raid and will warn you. It then gives you the option to continue creating a new array or not.

Create an ext3 file system on the newly created RAID device with the label “daten1″:

mkfs --type=ext3 -L daten1 /dev/md0

This takes quite a while.

To automatically start the RAID, it must be added to mdadm.conf:

mdadm -Es | grep md[0-9]  >>/etc/mdadm/mdadm.conf

Note that this will append to mdadm.conf, so if you execute it multiple times you will get duplicate entries. So make sure to check the file afterwards.

To mount the partition, it must be added to /etc/fstab like this:

/dev/md0    /mnt/daten1   ext3    defaults,noauto

noauto means that it should not be mounted automatically on boot. This is a safeguard against boot failures on headless servers. If any of the automatically mounted devices fails. We don’t reboot our servers very often so we will just ssh into it after reboot and mount the partition manually with

mount /mnt/daten1

To check the RAID status, use

cat /proc/mdstat

by dummzeuch at October 08, 2014 10:18 AM

Using parted to partition a drive

This is just a reminder to myself so I don’t forget again.

Warning: Use this on your own risk! You might lose all the data stored on any of the hard disk drives if you make a mistake!

On Linux hard drives > 2 GB must be partitioned with parted and a partition table in gpt format.

Create a new gpt partition table (deleting the entire drive!):

parted /dev/sdX mklabel gpt

Create a new partition spanning the entire drive and using optimal alignment:

parted -a opt /dev/sdX mkpart primary 0% 100%

Set a partition’s raid flag:

parted /dev/sdX set 1 raid on

by dummzeuch at October 08, 2014 09:52 AM

DWScript news and sneak peek

Below is a quick summary of changes in the SVN since the last post. There is also a mini-sneak peek of things to come! Recent changes Language changes Arrays can now be concatenated with the ‘+’ operator (same as XE7), note that it is supported for static arrays too, but a concatenation of static arrays results…

by Eric Grange at October 08, 2014 09:12 AM

October 07, 2014

Firebird News

New Firebird interface (cloop) – Cross Language Object Oriented Programming

Adriano wrote on Firebird-devel and twitter : I put in my github account the first version of cloop – Cross Language Object Oriented Programming. – This first version is limited to void and int datatypes, supports C, C++ and Free Pascal, and the makefile works only in POSIX. Some files in src/tests/test1 are autogenerated. […]

by mariuz at October 07, 2014 09:53 AM

Mini-interviews with speakers Firebird Conference 2014 speakers roundup

Alexey Kovyazin wrote on linkedin Firebird group : We started series of mini-interviews with Firebird Conference 2014 speakers: Ann Harrison: Paul Reeves: Mark Rotteveel: Stay tuned for more interviews! Don’t miss the last chance to register at Firebird event of the year: Prague, October 24-25:

by mariuz at October 07, 2014 07:47 AM

The Wiert Corner - irregular stream of stuff


Calling Randomize too often can make your Random numbers even less random.

Sometimes having the Randomize call in a unit initialization section is not practical.

Hence this little method that I think I first wrote back in the Turbo Pascal days:

procedure RandomizeIfNeeded();
  if RandSeed = 0 then 


Filed under: Delphi, Delphi 1, Delphi 2, Delphi 2005, Delphi 2006, Delphi 2007, Delphi 2009, Delphi 2010, Delphi 3, Delphi 4, Delphi 5, Delphi 6, Delphi 7, Delphi 8, Delphi for PHP, Delphi x64, Delphi XE, Delphi XE2, Delphi XE3, Delphi XE4, Development, Pascal, Software Development, Turbo Pascal

by jpluimers at October 07, 2014 05:00 AM

October 06, 2014

The Podcast at

Meet Me in São Paulo, Brazil at the Embarcadero Conference

Last year was my first visit to the Embarcadero Conference in São Paulo, Brazil and I loved it. So I am going back again this year. As an added treat I’m be joining Marco Canto, the Delphi product manager. We both speak together on Delphi Present and Future, then Marco does The Fun Side of Delphi and later I’ll cover Internet of Things, Bluetooth and AppTethering when I will also show some Delphi powered Brain-Computer Interface demos and a lucky volunteer will fly a quadricopter with their thoughts.

The Embarcadero Conference in Brazil is huge with a lot of great sessions. I always consider it a treat when I get to see Marco’s Fun Side of Delphi presentation. I wonder if he will show off the Elf & Wizard classes that are new in XE7?

by Jim McKeeth at October 06, 2014 11:59 PM

October 05, 2014

Castle Game Engine news

Many new Spine features in Castle Game Engine :) 1. slot timeline attachment (see the blast of spineboy...

Many new Spine features in Castle Game Engine :)

1. slot timeline attachment (see the blast of spineboy weapon, the movement of dragon wings, blinking of goblin eyes, and appearing of Venice hero watch),
2. correct bone/slot resetting to the pose mode at the beginning of each animation,
3. Bezier curves for animating parameters.

October 05, 2014 01:10 PM

October 03, 2014

Firebird News

Mini-interview about Firebird Conference 2014 with Mark Rotteveel

Today’s guest is Mark Rotteveel, developer of JayBird, Firebird JDBC driver, and speaker at Firebird Conference 2014.

by mariuz at October 03, 2014 09:15 AM