🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.readers
7 messages
7 total messages Started by A.Translator Fri, 22 Apr 2005 16:10
[dialog] play sound script error
#165696
Author: A.Translator
Date: Fri, 22 Apr 2005 16:10
27 lines
1749 bytes
After I reinstalled Windows and Dialog, I wanted to use the following 
script to play a sound when my messages were replied to:


in program OnXover;
-----
function PlaySound( Filename: PChar; Options: LongWord ): Boolean;
         external 'sndPlaySoundA@winmm.dll stdcall';

procedure OnXover(Var XoverData:TXoverData);
begin
if pos('@www.translatoria.com',xoverdata.references)>0 then
 PlaySound( 'c:\windows\media\chimes.wav', 1 );
----------

On compiling this error is given:
[error] OnXOver.ds (6.1): Identifier expected.

I am using the latest beta 38, vs 2.0.15.1

Can anyone help me?
Thanks.

-- 
Groet,
Adriana.
[Throw rubbish out if you want to reach me by e-mail]
Re: [dialog] play sound script error
#165698
Author: Korbinian Abenthum
Date: Fri, 22 Apr 2005 16:28
31 lines
2075 bytes
A.Translator wrote:

[script]

> On compiling this error is given:
> [error] OnXOver.ds (6.1): Identifier expected.

Hmm. Which line is #6?
If I put the following into my OnXOver-event-script

-- 8< -- snip -- 8< --

function PlaySound( Filename: PChar; Options: LongWord ): Boolean;
         external 'sndPlaySoundA@winmm.dll stdcall';

procedure OnXover(Var XoverData:TXoverData);
begin
if pos('@www.translatoria.com',xoverdata.references)>0 then
 PlaySound( 'c:\windows\media\chimes.wav', 1 );
end;

begin
end.

-- 8< -- snap -- 8< --

it compiles just fine.
(Although I did not test if it's actually working)

-- 
"I am no stranger to Valyrian steel." - Joffrey Baratheon
Re: [dialog] play sound script error
#165701
Author: A.Translator
Date: Fri, 22 Apr 2005 19:14
14 lines
1486 bytes
Op Fri, 22 Apr 2005 18:28:43 +0200 schreef Korbinian Abenthum:

> Hmm. Which line is

It says: 
function PlaySound( Filename: PChar; Options: LongWord ): Boolean;
         external 'sndPlaySoundA@winmm.dll stdcall';

And it used to work for me just fine, prior to the whole reinstall
business.
-- 
Groet,
Adriana.
[Throw rubbish out if you want to reach me by e-mail]
Re: [dialog] play sound script error
#165733
Author: Korbinian Abenthum
Date: Sat, 23 Apr 2005 11:30
14 lines
1876 bytes
A.Translator wrote:

> function PlaySound( Filename: PChar; Options: LongWord ): Boolean;
>          external 'sndPlaySoundA@winmm.dll stdcall';
> 
> And it used to work for me just fine, prior to the whole reinstall
> business.

Weird.
Did you try to throw it all out and only paste the 11-line-snippet I posted?
Cause I have a hard time believing that it's compiling here but not for you,
when we have the same DIALOG version.

If that's the case though then it's worth a Mantis bugreport.
Re: [dialog] play sound script error
#165740
Author: A.Translator
Date: Sat, 23 Apr 2005 15:22
15 lines
1850 bytes
Op Sat, 23 Apr 2005 13:30:26 +0200 schreef Korbinian Abenthum:

> Weird.
> Did you try to throw it all out and only paste the 11-line-snippet I posted?

Yes, and now it did compile.
Sorry, must have been too exhausted after having to do a complete reinstall
of my hard disk.

Is it you who wrote that script? Thanks! (It was one of the few things I
missed when I changed from Gravity to Dialog.)
-- 
Groet,
Adriana.
[Throw rubbish out if you want to reach me by e-mail]
Re: [dialog] play sound script error
#165746
Author: Korbinian Abenthum
Date: Sat, 23 Apr 2005 16:27
11 lines
1737 bytes
A.Translator wrote:

> Yes, and now it did compile.

OK.
Note that there is a version in the wiki which plays the sound only if it is
an immediate follow up to one of your postings (excluding your own).

> Is it you who wrote that script?

Oh no. Apparently Marcus ihmself wrote it.
Re: [dialog] play sound script error
#165758
Author: A.Translator
Date: Sat, 23 Apr 2005 18:29
9 lines
1594 bytes
Op Sat, 23 Apr 2005 18:27:30 +0200 schreef Korbinian Abenthum:

> Apparently Marcus ihmself wrote it.

Never mind, I am very grateful to whomever wrote it.
-- 
Groet,
Adriana.
[Throw rubbish out if you want to reach me by e-mail]
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