🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.readers
11 messages
11 total messages Started by ZER0 Fri, 02 Jul 2004 07:06
[Dialog] How {$include} directive works?
#151110
Author: ZER0
Date: Fri, 02 Jul 2004 07:06
24 lines
1590 bytes
Hi there,

I'd like save general stuff into a single file, like a "library", and
include it in my scripts.

I know the {$I} / {$include} directive, but the compiler give me the
follows error:

Could not find included script file "nameoflib.ds"

I put "nameoflib.ds" in the same directory of main script; in the root
directory of dialog; in "Scripts" directory.. but the compiler give me
always this error.

So, where I'm wrong..?

TIA

-- 
ZER0://coder.gfxer.web-designer/

~ Plagiarism is copying from one source;
research is copying from two or more
(Wilson Mizner)
Re: [Dialog] How {$include} directive works?
#151142
Author: Keith
Date: Fri, 02 Jul 2004 21:19
11 lines
1734 bytes
On Fri, 2 Jul 2004 09:06:49 +0200, ZER0 wrote:

> So, where I'm wrong..?

You will probably have better luck with a question in a Perl newsgroup.

-- 
Best Regards, Keith   http://kilowatt-radio.org/ NW Oregon Radio Page
Tried of Virus, Spyware, Adware and Popups? Switch To Mozilla Web
Browser and Email http://mozilla.org/ Recommended by the US 
Government Computer Security Team http://www.cert.gov/ 
Re: [Dialog] How {$include} directive works?
#151246
Author: ZER0
Date: Mon, 05 Jul 2004 06:24
14 lines
1529 bytes
On Fri, 2 Jul 2004 14:19:44 -0700, Keith wrote:

>> So, where I'm wrong..?
 
> You will probably have better luck with a question in a Perl newsgroup.

Perl..? I'm talking about 40tude Dialog newsreader scripting language.


-- 
ZER0://coder.gfxer.web-designer/

~ "When you have eliminated the impossible, whatever remains,
however improbable, must be the truth." (S.H.)
Re: [Dialog] How {$include} directive works?
#151247
Author: Jernej
Date: Mon, 05 Jul 2004 06:34
12 lines
1616 bytes
on Fri, 2 Jul 2004 09:06:49 +-0200, ZER0 wrote:

> Could not find included script file "nameoflib.ds"

Try just {$include MyScript} (and make sure you see MyScript.ds on the
Custom scripts tab).

-- 
begin  .sig
< Jernej Simon+AQ0-i+AQ0- ><+Jco->< http://www2.arnes.si/~sopjsimo/ >
< jernej simoncic at isg si ><http://deepthought.ena.si/>
end
Re: [Dialog] How {$include} directive works?
#151249
Author: ZER0
Date: Mon, 05 Jul 2004 06:46
20 lines
1653 bytes
On Mon, 5 Jul 2004 08:34:20 +0200, Jernej Simončič wrote:

>> Could not find included script file "nameoflib.ds"
 
> Try just {$include MyScript} (and make sure you see MyScript.ds on the
> Custom scripts tab).

Perfect!
Thanks a lot, now it works! I knew that it was a "columbo egg".. So, the
zRas example is wrong. :/

Can I ask you another question? It's possible make a class in Dialog
Scripting Language, for create custom object?

TIA!

-- 
ZER0://coder.gfxer.web-designer/

~ L'ingegnere non vive, funziona.
Re: [Dialog] How {$include} directive works?
#151251
Author: Jernej
Date: Mon, 05 Jul 2004 07:53
12 lines
1747 bytes
on Mon, 5 Jul 2004 08:46:23 +-0200, ZER0 wrote:

> Can I ask you another question? It's possible make a class in Dialog
> Scripting Language, for create custom object?

Nope, the script engine doesn't support classes.

-- 
begin  .sig
< Jernej Simon+AQ0-i+AQ0- ><+Jco->< http://www2.arnes.si/~sopjsimo/ >
< jernej simoncic at isg si ><http://deepthought.ena.si/>
end
Re: [Dialog] How {$include} directive works?
#151253
Author: ZER0
Date: Mon, 05 Jul 2004 07:58
14 lines
1648 bytes
On Mon, 5 Jul 2004 09:53:27 +0200, Jernej Simončič wrote:

>> Can I ask you another question? It's possible make a class in Dialog
>> Scripting Language, for create custom object?
 
> Nope, the script engine doesn't support classes.

I suppose it.. And DSL doesn't sopport random function as well, right?

-- 
ZER0://coder.gfxer.web-designer/

~ Alcune persone sono ancora vive per il semplice motivo che e'
illegale ucciderle.
Re: [Dialog] How {$include} directive works?
#151267
Author: matija
Date: Mon, 05 Jul 2004 19:41
10 lines
1942 bytes
ZER0, completely geschtonkenflapped, wrote:
> And DSL doesn't sopport random function as well, right?

     i made one recently for MLC, but i don't have it anymore :/


-- 
there is a cheer. the gnomes have learned a new way to say hooray.   [-shpongle]

address is scrambled - remove the superfluous "x" marks to reply
Re: [Dialog] How {$include} directive works?
#151268
Author: Lars Biskupek
Date: Mon, 05 Jul 2004 20:05
35 lines
2211 bytes
5.7.2004, *matija*:

> ZER0, completely geschtonkenflapped, wrote:
>> And DSL doesn't sopport random function as well, right?

>      i made one recently for MLC, but i don't have it anymore :/

Do you mean the one you posted in Dialog's betatest-group?

That was:

| program random_number;
| 
| function getTickCount : cardinal; external 'GetTickCount@kernel32.dll stdcall';
| 
| function random : double;
| var rand_real : double;
|     rseed : integer;
| begin            
|   rseed := getTickCount;
|   rseed := rseed*134775813 + 1;
|   if rseed < 0
|     then rand_real := rseed/4294967296.0 + 1.0
|     else rand_real := rseed/4294967296.0;
|   result := rand_real;
| end;
| 
| begin
|   writeln(floattostr(random));
| end.

-- 
HTH,

L a r s   B i s k u p e k
Re: [Dialog] How {$include} directive works?
#151280
Author: ZER0
Date: Tue, 06 Jul 2004 08:12
14 lines
1688 bytes
On Mon, 5 Jul 2004 21:41:19 +0200, matija wrote:

>> And DSL doesn't sopport random function as well, right?
 
>      i made one recently for MLC, but i don't have it anymore :/

I made one too.. I've use a old pascal source code, but thanks anyway. :)

-- 
ZER0://coder.gfxer.web-designer/

~ Come devo regolare la stampante laser per stordire?
(How do I set a laser printer to stun?)
Re: [Dialog] How {$include} directive works?
#151286
Author: ZER0
Date: Tue, 06 Jul 2004 14:39
24 lines
2244 bytes
On Mon, 5 Jul 2004 22:05:47 +0200, Lars Biskupek wrote:

>| function getTickCount : cardinal; external 'GetTickCount@kernel32.dll stdcall';

Mhm. In your opinion, is better link an external DLL for create the random
seed, or write in "scripting only" the follow code?

t:=DateTimeToTimeStamp(Now);
rseed:=t.time;

In addition, there is a difference: getTickCount returns the number of
milliseconds that have elapsed since Windows was started.

So, what's better?

TIA

-- 
ZER0://coder.gfxer.web-designer/

~ Alcune persone sono ancora vive per il semplice motivo che e'
illegale ucciderle.

on air ~ "Wedding Songs - Kissing You (instrumental)"
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads