Table of Contents
Why my Clipper applications could not run in new fast processor (Celeron, Pentium II/III, AMD, Cyrix) ?
How can I put a stamp of linking date and application version in the executables ?


Why my Clipper applications could not run in new fast processor (Celeron, Pentium II/III, AMD, Cyrix) ?
Internally, during application start-up, Clipper put a small code to calculate the delay factor according to the speed of the processor in which it is running. However, due to recent technology in fast processors, Clipper wrongly calculate the delay factor to 0, therefore an error of "Divide by zero" will occur.

Actually the solution is very simple, by linking in __wait_b.obj you could solve this problem easily. However, a lot of Clipperhead used the wrong solution by using __wait_4.obj found in CA-Clipper 5.3x; and sometimes the same error occurs. Take my word, use __wait_b.obj instead of __wait_4.obj will solve it forever.

Download __wait_b.obj now

Go Top


How can I put a stamp of linking date and application version in the executables ?
I always put the date and time of linking, application and database version number. To do this, I utilize Blinker's feature of embedding serial number into the executables directly. Please read my link script and source code thoroughly, as follows:

// Make script
app.exe: main.obj etc.obj
  dInfo 1.01 #030
  blinker @app @dInfo

// Source code to generate dInfo.lnk
function dInfo( _cLinkVersion, _cDBFversion )
  local hnd

  default _cLinkVersion to "0.01", _cDBFversion to "#001"

  hnd := fCreate( "dInfo.lnk" )
  if hnd > 0
    fWrite( hnd, "blinker executable serial " + ;
                  dToS( date() ) + " " + ;
                  subStr( time(), 1, 5 ) + " " + ;
                  padR( _cLinkVersion, 4 ) + " " + ;
                  padR( _cDBFversion, 4 ) )
    fClose( hnd )
    ? memoRead( "dInfo.lnk" )
  endif
return nil

// Source code to retrieve Date Linking and Version Number
static cBliSerNum, dLinkDate, cLinkTime, cLinkVersion, cDBFversion

init function __dInfo()

  cBliSerNum   := bliSerNum()
  dLinkDate    := stod( subStr( cBliSerNum, 1, 8 ) )
  cLinkTime    := subStr( cBliSerNum, 10, 5 )
  cLinkVersion := subStr( cBliSerNum, 16, 4 )
  cDBFversion  := subStr( cBliSerNum, 21, 4 )
return nil

function dInfoLinkDate()
return dLinkDate

function dInfoLinkTime()
return cLinkTime

function dInfoLinkVersion()
return cLinkVersion

function dInfoDBFversion()
return cDBFversion

Go Top