Solved

Bloodshed Dev-C++ Error with system("pause")

Posted on 2009-04-05
3
1,279 Views
Last Modified: 2012-05-06
Until recently, I have been able to use the system("pause"); command without any issue. Now when using it, it returns an error indicating that it is the first time I am using it and it has not been declared. Can someone help me figure out why I am getting this error now?

In function `int main()':
44 `system' undeclared (first use this function)
(Each undeclared identifier is reported only once for each function it appears in.)
0
Comment
Question by:ssharp77
  • 2
3 Comments
 
LVL 53

Accepted Solution

by:
Infinity08 earned 500 total points
ID: 24072587
For using the system function, you need to #include <stdlib.h>
0
 
LVL 53

Assisted Solution

by:Infinity08
Infinity08 earned 500 total points
ID: 24072588
Or in case it's C++ :

    #include <cstdlib>
0
 

Author Closing Comment

by:ssharp77
ID: 31566805
That's what I forgot to do. The ever basic #include . Ugh. Thanks as always Infinity!
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
thread-safe code in c++ 2 84
Microsoft C++ code failing in executable that worked 9 85
C++ mouse_event mouse look 7 70
Why isn't object file created? 6 42
How to Win a Jar of Candy Corn: A Scientific Approach! I love mathematics. If you love mathematics also, you may enjoy this tip on how to use math to win your own jar of candy corn and to impress your friends. As I said, I love math, but I gu…
Go is an acronym of golang, is a programming language developed Google in 2007. Go is a new language that is mostly in the C family, with significant input from Pascal/Modula/Oberon family. Hence Go arisen as low-level language with fast compilation…
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 be introduced to the technique of using vectors in C++. The video will cover how to define a vector, store values in the vector and retrieve data from the values stored in the vector.

920 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

16 Experts available now in Live!

Get 1:1 Help Now