944,001 Members | Top Members by Rank

Ad:
-1

This is a visual basic 6.0 wav sound player class that plays any selected sound file in .wav format. It has the filename property to select the file and play property to play the sound file.

by on Feb 3rd, 2006
This is a visual basic 6.0 wav sound player class that plays any selected sound file in .wav format. It has the filename property to select the file and play property to play the sound file. Visit http://www.mycplus.com for more codes.
Visual Basic 4 / 5 / 6 Code Snippet (Toggle Plain Text)
  1. Option Explicit
  2. Private mfilename As String
  3. Private mflags As Long
  4. Private Declare Function sndPlaySound Lib "winmm.dll" Alias "sndPlaySoundA" (ByVal lpszSoundName As String, ByVal uFlags As Long) As Long
  5.  
  6.  
  7. Public Property Get filename() As String
  8. filename = mfilename
  9. End Property
  10.  
  11. Public Property Let filename(ByVal vnewvalue As String)
  12. mfilename = vnewvalue
  13. End Property
  14.  
  15. Public Property Get flags() As Long
  16. flags = mflags
  17. End Property
  18.  
  19. Public Property Let flags(ByVal vnewvalue As Long)
  20. mflags = vnewvalue
  21. End Property
  22.  
  23. Public Sub play()
  24. Dim rc As Long
  25. rc = sndPlaySound(mfilename, mflags)
  26. End Sub
Comments on this Code Snippet
Mar 4th, 2007
0

Re: This is a visual basic 6.0 wav sound player class that plays any selected sound file in .wav format. It has the filename property to select the file and play property to play the sound file.

how to select the file what we want..
where we have to place the code..
Newbie Poster
karthik_02 is offline Offline
2 posts
since Mar 2007
Dec 25th, 2007
0

Re: This is a visual basic 6.0 wav sound player class that plays any selected sound file in .wav format. It has the filename property to select the file and play property to play the sound file.

Actually that is the implementation of a class module in VB, to play a specified file you will need to import this class into your project and then set the property filename to the files you want to play.
Junior Poster in Training
msaqib is offline Offline
91 posts
since Sep 2004
Dec 16th, 2008
0

Re: This is a visual basic 6.0 wav sound player class that plays any selected sound file in .wav format. It has the filename property to select the file and play property to play the sound file.

Hi there, Thanks for the website and lots of appreciations.
I am a beginner in VB6.
I want to know how to put the systems master control of audio panel in my application of MMControl. and regulate the volume of out put.
How to make the videoscreen of this MMcontrol to full screen.!!
How to make the form fullscreen at run time with the controls proportionally expanded in the page.
How to open existing PDF or Doc files through this VB application.
I request an immediate reply. Thanks in advance and ATB.
If possible, please send a reply to my email id also :
mankind33@gmail.com
Newbie Poster
mankind33 is offline Offline
3 posts
since Dec 2008
May 28th, 2010
0

Re: This is a visual basic 6.0 wav sound player class that plays any selected sound file in .wav format. It has the filename property to select the file and play property to play the sound file.

This code is helpful to play your recorded sound with the .wav format
Newbie Poster
surajcrj is offline Offline
1 posts
since May 2010
Message:
Previous Thread in Visual Basic 4 / 5 / 6 Forum Timeline: listview
Next Thread in Visual Basic 4 / 5 / 6 Forum Timeline: University Management System





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC