|
-
Sep 19th, 2000, 06:36 PM
#1
Thread Starter
Frenzied Member
you know how if your computer gets really frozen up, the internal system speackers make this BEEP sound. I was wondering how I can make that sound through vb (in otherwords, access the internal speaker system) ?
NXSupport - Your one-stop source for computer help
-
Sep 19th, 2000, 06:40 PM
#2
Try the Beep function.
Code:
Private Sub Command1_Click()
Beep
End Sub
-
Sep 19th, 2000, 06:47 PM
#3
Thread Starter
Frenzied Member
thats the windows extrenal speaker beep like the one that comes up when message boxes come up
I mean the internal speakers
NXSupport - Your one-stop source for computer help
-
Sep 19th, 2000, 08:27 PM
#4
Addicted Member
THAT's a REAL BEEP
look for
WIN95IO.dll
and install them,
Declare in vb:
Code:
Private Declare Sub vbOut Lib "WIN95IO.DLL" (ByVal nPort As Integer, ByVal nData As Integer)
Private Declare Function vbInp Lib "WIN95IO.DLL" (ByVal nPort As Integer) As Integer
And put those subs :
Code:
Private Sub Sound(Freq)
vbOut 67, 182
vbOut 66, CInt(1193280 / Freq) And 255
vbOut 66, CInt(1193280 / Freq) \ 256
vbOut 97, vbInp(97) Or 3
End Sub
Private Sub SoundOff()
vbOut 97, 0
End Sub
To beep:
Code:
Sound(Freq) 'Freq = 40 to ~1000
To stop the beep :
[code]
SoundOff
[/beep]
-
Sep 19th, 2000, 08:28 PM
#5
Addicted Member
Sorry for the [/beep] , dont put that..
and the freq is 40 to ~1000
-
Sep 19th, 2000, 08:37 PM
#6
Thread Starter
Frenzied Member
that dll comes with win 98 right?
becuase I'm gonna take the program to school, and run it there, they have win 98, so my program is like 28k so the vb run time files, and my exe fit onto one floppie, so do I need to distrubite this file too? or does it come standard on win 98?
NXSupport - Your one-stop source for computer help
-
Sep 20th, 2000, 09:48 PM
#7
Addicted Member
Me, I dont have it and I run under Win 98 SE ..
( not installed ?? )
dont take chance..
the DLL is only 4.00 Kb
juste look and download him..
-
Sep 20th, 2000, 09:49 PM
#8
Thread Starter
Frenzied Member
I found the file on the internet, and I downloaded it, but it doesn't work for me. I have a Athlon 550 mother board with win98 SE
NXSupport - Your one-stop source for computer help
-
Sep 20th, 2000, 09:53 PM
#9
Addicted Member
my ICQ is 63413316
I will send you and exemple whit the DLL
-
Sep 20th, 2000, 09:55 PM
#10
Thread Starter
Frenzied Member
I'm sorry, I tried ICQ again, but it just doesn't work for me, so I uninstalled it, I have AOL my screen name is dimava.... and my email is [email protected], can you please send the sample project there?
NXSupport - Your one-stop source for computer help
-
Sep 21st, 2000, 01:48 AM
#11
Do you have a sound card installed
We have found that some drivers over ride the beep. If ya do then try running your program on a pc without an intenral sound card, (if you can find one).
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|