Solved

Sound-C++ newbie!

Posted on 1998-06-21
2
192 Views
Last Modified: 2010-04-10
Sure this is an easy one! But I can't seem to find it in my books. Anyway, I am trying to put in an audible beep if the user enters an invalid entry. Using Borland C++ compiler. How do i go about doing this?
0
Comment
Question by:nt2mch
  • 2
2 Comments
 
LVL 22

Accepted Solution

by:
nietod earned 10 total points
ID: 1166391
I assume this is for a windows program.  If so use the Beep() or MessageBeep() Windows API procedures.
0
 
LVL 22

Expert Comment

by:nietod
ID: 1166392
If this is for a DOS program, you can write a BEL control character to the console, like

const char BEL = 7;
cout << BEL;
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Introduction This article is the first in a series of articles about the C/C++ Visual Studio Express debugger.  It provides a quick start guide in using the debugger. Part 2 focuses on additional topics in breakpoints.  Lastly, Part 3 focuses on th…
Introduction This article is a continuation of the C/C++ Visual Studio Express debugger series. Part 1 provided a quick start guide in using the debugger. Part 2 focused on additional topics in breakpoints. As your assignments become a little more …
The viewer will learn how to user default arguments when defining functions. This method of defining functions will be contrasted with the non-default-argument of defining functions.
The viewer will learn additional member functions of the vector class. Specifically, the capacity and swap member functions will be introduced.

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now