Jump to content
Sign in to follow this  
Srecko

MsgBox sound problem in Windows 10

Recommended Posts

Hi,

I have a problem with MsgBox sounds.

No sound is heard when a message appears regardless of which flag I use.

I just installed the latest version of autoit and SciTE, but the problem still exists.

Share this post


Link to post
Share on other sites

Srecko,

Welcome to the AutoIt forums.

There is nothing in the AutoIt function to affect/change the sound - have you checked your Windows sound settings?

M23


Public_Domain.png.2d871819fcb9957cf44f4514551a2935.png Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind

Open spoiler to see my UDFs:

Spoiler

ArrayMultiColSort ---- Sort arrays on multiple columns
ChooseFileFolder ---- Single and multiple selections from specified path treeview listing
Date_Time_Convert -- Easily convert date/time formats, including the language used
ExtMsgBox --------- A highly customisable replacement for MsgBox
GUIExtender -------- Extend and retract multiple sections within a GUI
GUIFrame ---------- Subdivide GUIs into many adjustable frames
GUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView items
GUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeView
Marquee ----------- Scrolling tickertape GUIs
NoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxes
Notify ------------- Small notifications on the edge of the display
Scrollbars ----------Automatically sized scrollbars with a single command
StringSize ---------- Automatically size controls to fit text
Toast -------------- Small GUIs which pop out of the notification area

 

Share this post


Link to post
Share on other sites

MsgBox does not affect sound in one way or another. If you want a sound to be played, when you call MsgBox you will have to make a separate sound event.


Who lied and told you life would EVER be fair?

Share this post


Link to post
Share on other sites
1 hour ago, benched42 said:

MsgBox does not affect sound in one way or another. If you want a sound to be played, when you call MsgBox you will have to make a separate sound event.

Oh, but why get i some sound testing this example:

#include <MsgBoxConstants.au3>

Local $iTimeout = 10

; Display a message box with a nested variable in its text.
MsgBox($MB_SYSTEMMODAL + $MB_ICONWARNING, "Title", "This message box will timeout after " & $iTimeout & " seconds or select the OK button.", $iTimeout)

 

Edited by AutoBert

Share this post


Link to post
Share on other sites
15 hours ago, AutoBert said:

Oh, but why get i some sound testing this example:

#include <MsgBoxConstants.au3>

Local $iTimeout = 10

; Display a message box with a nested variable in its text.
MsgBox($MB_SYSTEMMODAL + $MB_ICONWARNING, "Title", "This message box will timeout after " & $iTimeout & " seconds or select the OK button.", $iTimeout)

 

That is because you are calling $MB_ICONWARNING.  Flag 48 produces a warning icon and plays the sound.  Also take note that flag 16 and 64 also plays a sound.  The other flags do not but you can combine the flags to produce the sound.  See examples below.

; Script Start - Add your code below here
MsgBox(65,"","Hello World!") ; Flag 1 (Ok and Cancel) + 64 (Information icon)
MsgBox(20,"","Hello World!") ; Flag 4 (Yes and No) + 16(stop icon)

 

Edited by LisHawj
Code correction

Share this post


Link to post
Share on other sites
4 hours ago, LisHawj said:

That is because you are calling $MB_ICONWARNING. 

and which of these ways:

21 hours ago, benched42 said:

MsgBox does not affect sound in one way or another.

i used?

I get sounds on all $MB_ICON* flags.

Share this post


Link to post
Share on other sites
30 minutes ago, AutoBert said:

and which of these ways:

i used?

I get sounds on all $MB_ICON* flags.

I apologize, but I am not sure I understand what is being asked here.  Please clarify your question or statement.

Edited by LisHawj

Share this post


Link to post
Share on other sites

I apologize to everyone, it's not a problem in the autoit.
The problem is in my operating system.
I tested on multiple computers and worked on everyone.

Share this post


Link to post
Share on other sites
12 hours ago, Srecko said:

The problem is in my operating system.

Then let us know, which system and build version. And can you confirm, that other winapps have same problem with MsgBox?

Edited by AutoBert

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...