ghkweon / dwscript

Automatically exported from code.google.com/p/dwscript
0 stars 0 forks source link

Error compiling the UIB database driver with UIB lib in "no components" mode #413

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
The UIB lib has a compiler switch whether to compile the objects in the lib as 
(non-visual)components or not - the UIB_NO_COMPONENT define in the uib.inc 
file. I happen to have the define active so I got error when compiling the 
dwsUIBDatabase.pas file:

[DCC Error] dwsUIBDatabase.pas(154): E2034 Too many actual parameters
[DCC Error] dwsUIBDatabase.pas(163): E2034 Too many actual parameters
[DCC Error] dwsUIBDatabase.pas(210): E2034 Too many actual parameters
[DCC Error] dwsUIBDatabase.pas(242): E2034 Too many actual parameters

Easy to fix but it would be nice if there would be an place (DWS.inc ?) where I 
could define in which mode I have compiled the UIB so that one wouldn't need to 
change dwsUIBDatabase.pas itself.

Original issue reported on code.google.com by ain.val...@gmail.com on 4 Jun 2013 at 8:04

GoogleCodeExporter commented 8 years ago
If you define that setting at the project level, if conditional could be tested 
for in the dwsUIBdatabase unit? 

Original comment by zar...@gmail.com on 4 Jun 2013 at 9:50

GoogleCodeExporter commented 8 years ago
Yes, using code like

      FDB:=TUIBDataBase.Create{$IFNDEF UIB_NO_COMPONENT}(nil){$ENDIF};

in dwsUIBDatabase and then adding UIB_NO_COMPONENT to project's conditionals 
works.

Original comment by ain.val...@gmail.com on 4 Jun 2013 at 11:45

GoogleCodeExporter commented 8 years ago
This issue was closed by revision r2152.

Original comment by zar...@gmail.com on 4 Jun 2013 at 2:50