×
INTELLIGENT WORK FORUMS
FOR ENGINEERING PROFESSIONALS

Log In

Come Join Us!

Are you an
Engineering professional?
Join Eng-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Jobs

MsgBox in VB6

MsgBox in VB6

MsgBox in VB6

(OP)
Hello,

I would like to know if it's possible to take off the alert sound that a msgbox makes in VB???

Best regards, Carlos Cardoso

RE: MsgBox in VB6

Not without various hacks, as far as I know - it's a user setting. Using your own (custom) dialog box is the cleanest way around it.

RE: MsgBox in VB6

If you want you could use this code below do it, however the message box will be a Question message box.  The Question message box will not make the alert sound.

Heres the code:

prompt$ = "Put Message here"
reply = MsgBox(prompt$, vbQuestion, "Put title here")

Justin Dean,PE

RE: MsgBox in VB6

The alert sound is not a vb option, is a windows option that is on the control panel and sounds and multimedia, could be the question sound "chord.wav" that logically is on the registry

There's a key on the registry where you can find out about the sounds

HKEY_CURRENT_USER\Schemes\Apps\.Default

And in there most likely is the following the one that controls that sound:

HKEY_CURRENT_USER\Schemes\Apps\.Default\SystemQuestion\.Current

you can modify it on and off every time that you use your application. Well, is just and idea.

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members!


Resources