Click here to Skip to main content
15,921,276 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: how can i gei the menory size that one application used in vb Pin
huoyw7-Jun-04 21:11
huoyw7-Jun-04 21:11 
GeneralRe: how can i gei the menory size that one application used in vb Pin
Dave Kreskowiak8-Jun-04 0:29
mveDave Kreskowiak8-Jun-04 0:29 
GeneralDirectX Pin
zman9002-Jun-04 17:44
zman9002-Jun-04 17:44 
GeneralRe: DirectX Pin
Dave Kreskowiak3-Jun-04 3:37
mveDave Kreskowiak3-Jun-04 3:37 
GeneralRe: DirectX Pin
zman9003-Jun-04 19:24
zman9003-Jun-04 19:24 
GeneralRe: DirectX Pin
Dave Kreskowiak4-Jun-04 0:17
mveDave Kreskowiak4-Jun-04 0:17 
QuestionUi? Pin
Boggahutt872-Jun-04 13:29
Boggahutt872-Jun-04 13:29 
AnswerRe: Ui? Pin
Dave Kreskowiak3-Jun-04 3:30
mveDave Kreskowiak3-Jun-04 3:30 
Sound is a major component of a game. You should've had this integrated into your project a long time ago. Just slapping it in at the end... man...

Boggahutt87 wrote:
One of the options in the properties is "ui"

One of the properties of what? You didn't say what the class was that your looking at.

It is possible to play a wave file, but you'll have to use the Multimedia SDK, or DirectX DirectSound. I seriously doubt you want to use the MediaPlayer COM control to do this. Also, your getting into more complicated audio methods that REQUIRE a sound card to work. Just using the normal PC speaker, like you've been using with Beep, won't work.

Same as before. Declare the API function you want to call first:
Private Declare Function PlaySound Lib "Winmm" Alias "PlaySound" _
    (ByVal pszSound As String, ByVal hModule As Long, fdwSound As Long) As Long

Now, when you call this function, you have to supply it with 3 parameters:

1. pszSound will be the filename of the sound you want to play, like "SOUND.WAV". The .WAV file must be in the same directory as your compiled .EXE to work.
2. hModule must be 0.
3. fdwSound must be 0.

You'll call PlaySound like this:
PlaySound "SOUND.WAV", 0, 0


And remember! If you get smacked down by the teacher for using code he didn't tell you about, and therefore you couldn't possibly write Big Grin | :-D , it's not my fault! Poke tongue | ;-P


RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome

QuestionHow to get the default printer? Pin
Anonymous2-Jun-04 11:45
Anonymous2-Jun-04 11:45 
AnswerRe: How to get the default printer? Pin
Dave Kreskowiak3-Jun-04 3:08
mveDave Kreskowiak3-Jun-04 3:08 
GeneralRe: How to get the default printer? Pin
Anonymous3-Jun-04 4:02
Anonymous3-Jun-04 4:02 
GeneralRe: How to get the default printer? Pin
Dave Kreskowiak3-Jun-04 4:32
mveDave Kreskowiak3-Jun-04 4:32 
GeneralRe: How to get the default printer? Pin
Dave Kreskowiak3-Jun-04 4:46
mveDave Kreskowiak3-Jun-04 4:46 
GeneralRe: How to get the default printer? Pin
Anonymous3-Jun-04 4:41
Anonymous3-Jun-04 4:41 
GeneralRe: How to get the default printer? Pin
Dave Kreskowiak3-Jun-04 4:47
mveDave Kreskowiak3-Jun-04 4:47 
GeneralRe: How to get the default printer? Pin
Anonymous3-Jun-04 5:14
Anonymous3-Jun-04 5:14 
GeneralRe: How to get the default printer? Pin
Dave Kreskowiak3-Jun-04 5:44
mveDave Kreskowiak3-Jun-04 5:44 
GeneralRe: How to get the default printer? Pin
Anonymous3-Jun-04 6:37
Anonymous3-Jun-04 6:37 
GeneralLet's make more simple. Pin
Anonymous2-Jun-04 10:34
Anonymous2-Jun-04 10:34 
GeneralRe: Let's make more simple. Pin
Dave Kreskowiak3-Jun-04 2:52
mveDave Kreskowiak3-Jun-04 2:52 
GeneralModifying Selected EAP Type Pin
^eleK2-Jun-04 9:21
^eleK2-Jun-04 9:21 
GeneralRe: Modifying Selected EAP Type Pin
Dave Kreskowiak3-Jun-04 2:51
mveDave Kreskowiak3-Jun-04 2:51 
GeneralHelp needed - making vb6 LoadPicture faster Pin
steff kamush2-Jun-04 5:58
steff kamush2-Jun-04 5:58 
GeneralRe: Help needed - making vb6 LoadPicture faster Pin
Dave Kreskowiak2-Jun-04 12:31
mveDave Kreskowiak2-Jun-04 12:31 
GeneralRe: Help needed - making vb6 LoadPicture faster Pin
steff kamush3-Jun-04 0:42
steff kamush3-Jun-04 0:42 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.