you need to pass an explicit TVarRec argument to the LogDebug function when using a format string and array. This is similar to the behavior of the standard Format routine of Borland C++.
Fortunately, there is a C++ macro makes this a bit easier. It is called OPENARRAY and takes two arguments. The first is the array type (in our case TVarRec) and the second is the array itself.
So, when calling LogDebug with a format string, you can call it like this:
SiMain->LogDebug(“something %d”, OPENARRAY(TVarRec, (value)));
By the way, the SmartInspect installation comes with a set of live templates for BDS 2006 (including C++). Among others, there are templates for the functions which take a format string (LogDebug, LogVerbose etc.). For installation help, please have a look at our templates knowledge base article:
After installing the templates, you can enter “sidebf” in the code editor and expand this template by pressing Strg+J.