Genesys CTI User Forum

Genesys CTI User Forum => Genesys CTI Technical Discussion => Topic started by: NCSC_User on April 26, 2007, 05:59:06 PM

Title: VB Script Help for playing a .Wav file as an action
Post by: NCSC_User on April 26, 2007, 05:59:06 PM
Checked 20 pages of posts and couldn't find anything related to this.  Not sure if my problem is related to upgrading to version 7.2, me going from NT to XP Professional or a little bit of both.

All i need to do is have a .wav file on my C: play when a certain threshold is met.  It used to work like a charm.. now i get an error message.  Here's how the Action that used to work in NT was written:

'This script uses a COM component defined in
'GsSampleTEObjects.DLL the source code for which
'is included in the CCPulse installation package.  It should
'be compiled using Visual Basic in order for this script to work.

'Create the Genesys sound object
[b]Set SoundObject = CreateObject("GsSampleTEObjects.GsActionSoundObject")[/b]

'Specify the full path to a WAV file in order to play it.
[b]SoundObject.PlaySoundFile("c:\winnt\media\ccpulse wav\air_raid.wav")[/b]

Line 1-5 are just notes since they have ' in the front.  Lines 6 and 8 are the only ones being executed.

Since i'm on XP now i edited the path to say [b]SoundObject.PlaySoundFile("c:\GCTI\ccpulse\wav\air_raid.wav")[/b] which is where the file is now located but regardless i get the exact same error message when i test it now for [b]both[/b] examples.

Error is as follows:

[b]Error at
Line:6
Position: 0
Error Message: ActiveX component can't create object: 'GsSampleTEObjects.GsActionSoundObject'[/b]

Any ideas how to fix this?  It worked like a charm before.  All i had to do is change the name of the .wav file in the path if i wanted a different sound to play :(  I even tried putting the file right under C: and used the code [b]SoundObject.PlaySoundFile("c:\air_raid.wav")[/b] and still no luck :(

Title: Re: VB Script Help for playing a .Wav file as an action
Post by: René on April 26, 2007, 06:27:39 PM
Hi,

It seems to me that the COM object, you're calling, isn't registered properly on your system. Open command prompt, go the directory where the library GsSampleTEObjects.dll is stored and execute this command "regsvr32 GsSampleTEObjects.dll". You should receive a message that the registration was successful. Your threshold should work correctly then.

Regards,
René
Title: Re: VB Script Help for playing a .Wav file as an action
Post by: NCSC_User on April 26, 2007, 06:32:00 PM
How would i go about doing this?

I got as far as Start/Run/cmd  :D
Title: Re: VB Script Help for playing a .Wav file as an action
Post by: cavagnaro on April 26, 2007, 06:38:20 PM
lol well a small lesson on DOS

let say your dll file is on c:\gcti\ccpulse\objectsamples

as you said run/cmd

here do:

>cd c:\gcti\ccpulse\objectsamples
>regsvr32 GsSampleTEObjects.dll

done
Title: Re: VB Script Help for playing a .Wav file as an action
Post by: NCSC_User on April 26, 2007, 06:40:23 PM
ahh thanks.. now the new conundrum...

where the heck then is my dll file ... never ends does it. lol
Title: Re: VB Script Help for playing a .Wav file as an action
Post by: NCSC_User on April 26, 2007, 06:44:21 PM
actually after doing a hard drive search (including hidden files) it's no where to be found..

<Scratch head>

could i have lost that upgrading to 7.2? or possibly it's not included?  Is that the only code that can be used in Pulse to execute a .wav file as an action?
Title: Re: VB Script Help for playing a .Wav file as an action
Post by: mark on April 26, 2007, 10:57:17 PM
Its the easier way of doing it, I will upload our version for you tomorrow if nobody else has in the mean time!
Title: Re: VB Script Help for playing a .Wav file as an action
Post by: René on April 27, 2007, 06:45:27 AM
Hi,

You can't find the library because the source codes of it are part of CCPulse installation only. The compiled library is attached to this post. Download the file and unpack the archive. Copy the file "GsSampleTEObjects.dll" to the directory where your CCPulse was installed (it's not necessary but better to have CCPulse related libraries in one directory). Then follow the steps described by me and Cavagnaro.

Cheers,
René
Title: Re: VB Script Help for playing a .Wav file as an action
Post by: NCSC_User on April 27, 2007, 07:45:30 PM
Thanks everyone that was right on the money!  :D
Title: Re: VB Script Help for playing a .Wav file as an action
Post by: s.kulku on May 01, 2007, 03:33:36 AM
I have never heard of GsSampleTEObjects.dll. I\'ve looked through CCP manual and can\'t find any mentioning of it.
What is it and what does it do?

Sanja Kulku
Technical Development Manager
Title: Re: VB Script Help for playing a .Wav file as an action
Post by: cavagnaro on May 02, 2007, 03:50:11 PM
Read the CCPulse Help File.
It's a library to show that CCpulse can call any DLL and the Functions on it. Can be very cool.
Title: Re: VB Script Help for playing a .Wav file as an action
Post by: S on January 17, 2008, 09:51:51 PM
Thanks a lot, René for uploading the dll.

S  ;D  :)  :)>
Title: Re: VB Script Help for playing a .Wav file as an action
Post by: screaminbrod on October 31, 2008, 04:34:49 PM
Thanks Rene for the file. you're the best. ;)
Title: Re: VB Script Help for playing a .Wav file as an action
Post by: Adeel on January 26, 2009, 10:48:55 AM
Hey guys were can i find the file! i want to download it and cant seem to find it on the net.     
Title: Hi People
Post by: titikinkity on October 08, 2009, 06:06:33 AM
Hi People
How are you doing?
Title: Re: VB Script Help for playing a .Wav file as an action
Post by: MarkSixtyNine on November 15, 2011, 11:26:00 AM
Hi guys, I followed all the steps above, but when I press the TEST button in the Action Wizard the system returns me the message: "The script has timed out"

Can anyone help me? Thanks!
Title: Re: VB Script Help for playing a .Wav file as an action
Post by: Wein4tler on May 23, 2014, 05:03:53 PM

Hola,
how is it on 64-bit Windows - I have gotten an Error message when you run Regsvr32.exe on 64-bit Windows.

thanks in advance!