Page 1 of 1

PostPosted: Fri Nov 14, 2008 3:27 pm
by ERT
Hi,
_ There is a whole set of DCAL (Classic) routines that, though declared existing by an official DataCAD document (see: \DataCAD 12\DCAL\NewIn9.doc), I'm neither able to find nor to use. Here two examples:
Code:
PROCEDURE msg_OK (msg : str255); BUILTIN 245;
PROCEDURE readIniStr (IniFile, Section, Ident, Default : str255; ReturnStr : OUT str255); BUILTIN 625;
Does anybody have actually found and used some of them? I'd love to know where/how(*).

Thank you.
Pietro Moras


The classic DCAL is a special program language. The DCAL cannot run in windows, only inside DataCAD. In DCAL we cannot use Windows API directly. These entry points is a chance that we can use some windows API function in classic DCAL programs. Therefore the DataCAD programmers allow to access some Windows API function across the DataCAD.

For example:
ReadIniStr entry point
a part of the IniFiles source code in Delphi:
Code: Select allfunction TIniFile.ReadString(const Section, Ident, Default: string): string;
var
  Buffer: array[0..2047] of Char;
begin
  SetString(Result, Buffer, GetPrivateProfileString(PChar(Section),
    PChar(Ident), PChar(Default), Buffer, SizeOf(Buffer), PChar(FFileName)));
end;


PROCEDURE readIniStr (IniFile, Section, Ident, Default : str255; ReturnStr : OUT str255);
Read string value to the "ReturnStr" from the "IniFile" INI file, from "Section" section, from "Ident" parameter.
for example: inifile=DCADWIN.INI, section=KeyFile, ident=KeyFileName

I didn't use this functions in classic DCAL. I wrote classic DCAL programs in DOS platform until DataCAD 7.0. Now I'm a Delphi programmer.

ERT