Solved

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

Posted on 2009-04-05
3
1,321 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

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

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…
This article seeks to propel the full implementation of geothermal power plants in Mexico as a renewable energy source.
The goal of the video will be to teach the user the difference and consequence of passing data by value vs passing data by reference in C++. An example of passing data by value as well as an example of passing data by reference will be be given. Bot…
The viewer will learn additional member functions of the vector class. Specifically, the capacity and swap member functions will be introduced.

860 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