Post: clrscr() not a member of conio.h
03-04-2011, 08:33 PM #1
(adsbygoogle = window.adsbygoogle || []).push({}); Was developing a small console program in college today, and i noticed DevCpp debugger said clrscr() undefined function, i have include conio.h, so i started to wonder, is this a DevCpp problem? so i searched the conio.h library and found clrscr() is not even a member.

Does anyone know which library clrscr() is? please provide link to the source of your information.

Thanks.
Outie
(adsbygoogle = window.adsbygoogle || []).push({});
03-04-2011, 08:50 PM #2
kiwimoosical
Bounty hunter
You must login or register to view this content. - conio.h, update your libraries.
You must login or register to view this content.
You must login or register to view this content.

you can also fflush(stdout); to clear the screen as it flushes all resources (text) from stdout (cout/console output/cin/console input).
03-04-2011, 09:18 PM #3
Girby2K11
☮ ☯ ☢ ✔ ➝
yeah i had this problem with it on code::blocks. i think it only works in C programming not C++
03-04-2011, 09:32 PM #4
kiwimoosical
Bounty hunter
Originally posted by Girby2K11 View Post
yeah i had this problem with it on code::blocks. i think it only works in C programming not C++


Nope. C and C++ can be used in the same program.

like I said: fflush(stdout);
03-04-2011, 09:36 PM #5
Girby2K11
☮ ☯ ☢ ✔ ➝
Originally posted by kiwimoosical View Post
Nope. C and C++ can be used in the same program.

like I said: fflush(stdout);


ok. ima try it out now
03-05-2011, 10:31 AM #6
Originally posted by kiwimoosical View Post
Nope. C and C++ can be used in the same program.

like I said: fflush(stdout);


what library fflush? it looks file related in documentations.
03-05-2011, 02:47 PM #7
kiwimoosical
Bounty hunter
Originally posted by TheUberFail View Post
what library fflush? it looks file related in documentations.


#include <stdio.h>
03-05-2011, 03:19 PM #8
Originally posted by kiwimoosical View Post
#include <stdio.h>


    #include <iostream>
#include <windows.h>
#include <stdio.h>

using namespace std;

int main()
{
HANDLE hOut = GetStdHandle(STD_OUTPUT_HANDLE);

cout<<"Testing..";
fflush(hOut);
cout<<"did it work?"<<endl;
system("PAUSE");
return 0;
}


12 Sad Awesome\C++\Untitled3.cpp invalid conversion from `void*' to `FILE*'

Am i doing this right?
03-05-2011, 03:50 PM #9
kiwimoosical
Bounty hunter
Originally posted by TheUberFail View Post
    #include <iostream>
#include <windows.h>
#include <stdio.h>

using namespace std;

int main()
{
HANDLE hOut = GetStdHandle(STD_OUTPUT_HANDLE);

cout<<"Testing..";
fflush(hOut);
cout<<"did it work?"<<endl;
system("PAUSE");
return 0;
}


12 Sad Awesome\C++\Untitled3.cpp invalid conversion from `void*' to `FILE*'

Am i doing this right?


    #include <stdio.h>
void main(void) { std::cout<<"imma get cleared?";
fflush(std::stdout); //typing this ffrom my phone, may be wrong
std::cout<<"cleared"; system("pause");

Copyright © 2026, NextGenUpdate.
All Rights Reserved.

Gray NextGenUpdate Logo