#11 2016-06-23 14:32

Andrew
Senior Member
Registered: 2008-05-22
Posts: 542

Re: Pascalscript - include external procedure or function library?

Tested include files in 6.5.0.2β and everything seems to be working fine.

Is there any way to use more than 1 include file? I tried both:

{$INCLUDE 'path\file 1.inc', 'path\file 2.inc'}

and

{$INCLUDE 'path\file 1.inc'}
{$INCLUDE 'path\file 2.inc'}

but neither worked.

Also, the new Scripts\Example include file.inc has the following comment:

// This file is used for demonstrating the use of {%INCLUDE} directive.

%INCLUDE should be changed to $INCLUDE I guess.

Offline

#12 2016-06-26 01:01

den4b
Administrator
From: den4b.com
Registered: 2006-04-06
Posts: 3,374

Re: Pascalscript - include external procedure or function library?

Andrew wrote:

Is there any way to use more than 1 include file?

Yes, just repeat the {$INCLUDE} directive with different paths. Maybe there is a syntax error in your script?

Andrew wrote:

%INCLUDE should be changed to $INCLUDE I guess.

Fixed. Well spotted.

Offline

#13 2016-06-28 18:24

Andrew
Senior Member
Registered: 2008-05-22
Posts: 542

Re: Pascalscript - include external procedure or function library?

den4b wrote:

Yes, just repeat the {$INCLUDE} directive with different paths. Maybe there is a syntax error in your script?

Not quite sure what I did wrong when I tested it initially, but multiple includes are working fine now.

Did get slightly tripped up while testing because the include file path contained single quotes, until I remembered that those have to be doubled each time since backslash doesn't work as an escape character.

Offline

Board footer

Powered by FluxBB