My beep wont beep 
Author Message
 My beep wont beep

Hi

I just had a mental and tried to use Beep, but it doesn't work
nor does wscript.beep

Is there an alternative in VBS ? or do I have to run a sound file ?

--
Tom



Sun, 06 Jul 2003 17:00:22 GMT  
 My beep wont beep

Quote:

> Hi

> I just had a mental and tried to use Beep, but it doesn't work
> nor does wscript.beep

> Is there an alternative in VBS ? or do I have to run a sound file ?

> --
> Tom

Strange.  When I went to the Index tab in my WSH documentation and typed
BEEP, I didn't find an entry.  I even got a 'not topics' response in
Search.  I got the same result in VBScript.  Does your documentation
have an entry for this, where mine doesn't?  (Or could it mean there is
no such method. ;o)  (Sorry, I couldn't resists)

Yes, you will have to play a sound file (or find a third party control
or roll your own 'Beep' control).

Tom Lavedas
-----------
http://www.pressroom.com/~tglbatch/



Sun, 06 Jul 2003 22:17:04 GMT  
 My beep wont beep
hi Tom,

You can get a "beep" if you are courageous enough (or foolhardy enough) to
use a third-party control (and call an api).

   Declare Function Beep Lib "kernel32" Alias "Beep" _
        (ByVal dwFreq As Long, ByVal dwDuration As Long) As Long

cheers, jw


Quote:
> Hi

> I just had a mental and tried to use Beep, but it doesn't work
> nor does wscript.beep

> Is there an alternative in VBS ? or do I have to run a sound file ?

> --
> Tom



Mon, 07 Jul 2003 04:04:55 GMT  
 My beep wont beep
Thanks Jim

It looks fine to me, but causes an error (chr 9)

I assume it was to be used in a standalone .vbs script ?

Tom

Quote:
-----Original Message-----

hi Tom,

You can get a "beep" if you are courageous enough (or foolhardy enough) to
use a third-party control (and call an api).

   Declare Function Beep Lib "kernel32" Alias "Beep" _
        (ByVal dwFreq As Long, ByVal dwDuration As Long) As Long

cheers, jw



> Hi

> I just had a mental and tried to use Beep, but it doesn't work
> nor does wscript.beep

> Is there an alternative in VBS ? or do I have to run a sound file ?

> --
> Tom

.



Mon, 07 Jul 2003 05:04:40 GMT  
 My beep wont beep
yes.  It's not advisable to call api's from IE host, jw


Thanks Jim

It looks fine to me, but causes an error (chr 9)

I assume it was to be used in a standalone .vbs script ?

Tom

Quote:
-----Original Message-----

hi Tom,

You can get a "beep" if you are courageous enough (or foolhardy enough) to
use a third-party control (and call an api).

   Declare Function Beep Lib "kernel32" Alias "Beep" _
        (ByVal dwFreq As Long, ByVal dwDuration As Long) As Long

cheers, jw



> Hi

> I just had a mental and tried to use Beep, but it doesn't work
> nor does wscript.beep

> Is there an alternative in VBS ? or do I have to run a sound file ?

> --
> Tom

.



Mon, 07 Jul 2003 05:52:37 GMT  
 My beep wont beep
Jim

I was using it from a VBS standalone script - not IE
That's where I got the error

Can you help - or check the syntax please ?
It looks more for VB not VBS to me (but I am not any sort of expert)

Thanks
--
Tom


Quote:
> yes.  It's not advisable to call api's from IE host, jw



> Thanks Jim

> It looks fine to me, but causes an error (chr 9)

> I assume it was to be used in a standalone .vbs script ?

> Tom

> -----Original Message-----
> hi Tom,

> You can get a "beep" if you are courageous enough (or foolhardy enough) to
> use a third-party control (and call an api).

>    Declare Function Beep Lib "kernel32" Alias "Beep" _
>         (ByVal dwFreq As Long, ByVal dwDuration As Long) As Long

> cheers, jw



> > Hi

> > I just had a mental and tried to use Beep, but it doesn't work
> > nor does wscript.beep

> > Is there an alternative in VBS ? or do I have to run a sound file ?

> > --
> > Tom

> .



Mon, 07 Jul 2003 12:17:22 GMT  
 My beep wont beep
it's not vbscript but you can convert?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
this works in IE5

<script Language="Javascript"><!--
function beep()
{
    b.getToolkit().beep();

Quote:
}

-->
</script >

<OBJECT ID="b" CLASSID="java:java.awt.Button"
    STYLE="display: none;"></OBJECT>

<INPUT TYPE="BUTTON" VALUE="Beep" onClick="beep();" />

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~


Quote:
> Hi

> I just had a mental and tried to use Beep, but it doesn't work
> nor does wscript.beep

> Is there an alternative in VBS ? or do I have to run a sound file ?

> --
> Tom



Mon, 07 Jul 2003 15:16:34 GMT  
 My beep wont beep
hi Tom,

To call an api from script, you need a third-party control.  The "usual
suspect" in this case is a 3rd-party control called DynaWrap.  Here's how to
use it...

--- <snip> ---
' beep demo, jw 19Jan01

  ' instantiate DynaWrap...
  Set oDW = CreateObject("DynamicWrapper")
  ' declare the api call...
  oDW.Register "KERNEL32.DLL", "Beep", "i=ll", "f=s", "r=l"
  ' call the api (parameters are: frequency, duration)
  oDW.Beep 1000,1000

Set oDW = nothing  ' clean up
WScript.Quit
--- </snip> ---

DynaWrap is available from Clarence's or Guenter's websites, although you
may prefer
Guenter's as he provides some doc to go along with the code.

Clarence:
http://cwashington.netreach.net/main_site/downloads/default.asp?topic...

   (then look for: DynaWrap.dll)

Guenter:  http://www.borncity.com/WSHBazaar/WSHBazaar.htm

   (click on DynaCall page)

cheers, jw


Quote:
> Jim

> I was using it from a VBS standalone script - not IE
> That's where I got the error

> Can you help - or check the syntax please ?
> It looks more for VB not VBS to me (but I am not any sort of expert)

> Thanks
> --
> Tom



Wed, 09 Jul 2003 01:33:42 GMT  
 My beep wont beep
Jim

Thankyou for all this info
It appears I can progress from here  :-)

--
Tom


Quote:
> hi Tom,

> To call an api from script, you need a third-party control.  The "usual
> suspect" in this case is a 3rd-party control called DynaWrap.  Here's how
to
> use it...

> --- <snip> ---
> ' beep demo, jw 19Jan01

>   ' instantiate DynaWrap...
>   Set oDW = CreateObject("DynamicWrapper")
>   ' declare the api call...
>   oDW.Register "KERNEL32.DLL", "Beep", "i=ll", "f=s", "r=l"
>   ' call the api (parameters are: frequency, duration)
>   oDW.Beep 1000,1000

> Set oDW = nothing  ' clean up
> WScript.Quit
> --- </snip> ---

> DynaWrap is available from Clarence's or Guenter's websites, although you
> may prefer
> Guenter's as he provides some doc to go along with the code.

> Clarence:
> http://cwashington.netreach.net/main_site/downloads/default.asp?topic...

>    (then look for: DynaWrap.dll)

> Guenter:  http://www.borncity.com/WSHBazaar/WSHBazaar.htm

>    (click on DynaCall page)

> cheers, jw



> > Jim

> > I was using it from a VBS standalone script - not IE
> > That's where I got the error

> > Can you help - or check the syntax please ?
> > It looks more for VB not VBS to me (but I am not any sort of expert)

> > Thanks
> > --
> > Tom



Wed, 09 Jul 2003 01:52:19 GMT  
 
 [ 10 post ] 

 Relevant Pages 

1. Beep Beep Beep

2. Beep won't beep

3. gw-basic & windows95:BEEP does not beep

4. BEEP BEEP

5. Beep Beep !

6. One beep, Two beep, Three...

7. BEEP statement does not beep!

8. Beep Beep

9. BEEP in HTML page

10. Beep in HTML Page

11. unix/pc/postscript/beep/how?

12. Beeps when pressing enter at a text widget

 

 
Powered by phpBB® Forum Software