Solved

Turbo C++ 3.0 graphics

Posted on 2001-08-10
4
1,718 Views
Last Modified: 2008-01-09
I have turbo C++ installed , but none of the graphics functions work, like initgraph.It gives linking errors.
0
Comment
Question by:vmr_iitm
4 Comments
 
LVL 3

Expert Comment

by:null_pointer
ID: 6372458
If u could give the error details and the code u are using

0
 
LVL 3

Expert Comment

by:sumant032199
ID: 6372557
I think you are getting an error:

Graphics error: Device driver file not found (EGAVGA.BGI)
Press any key to halt:

If it is so then follo this.
In initgraph() the last parameter is
"char far * pathtodriver"
generally we use "" in that field. Use the complete
path like "C:\\TC\\BGI". Don't forget to use double \\
or else copy your *.BGI files in directory from where you run your program.
0
 

Accepted Solution

by:
kartik earned 50 total points
ID: 6373385
Hi,
I think you have to change the setting in the TC environment before using the graphics.
If you can give the exact error message that you recieve then it would be easy to find the solution.
But I suggest you try out the following things:
1>Go to "Options" menu in that "Linker" option and in that "libraries" option. Make sure that "Graphics" is selected.
2>Then in the "Option" menu go to "Directories" option and in that make sure that you have mentioned the correct Include directories path and Lib path.
As for eg:
Include path:
"C:\Tc\Include"
Library path:
"C:\Tc\Lib"
3>Then make sure that in your program you have include the "Graphics.h" header file.
4>Then make sure that in the third parameter of InitGraph function you have specified the path of BGI file.
i.e InitGraph(&gd,&gm,"C:\\Tc\\BGI");
0
 

Author Comment

by:vmr_iitm
ID: 6378635
It was correct
0

Featured Post

Optimizing Cloud Backup for Low Bandwidth

With cloud storage prices going down a growing number of SMBs start to use it for backup storage. Unfortunately, business data volume rarely fits the average Internet speed. This article provides an overview of main Internet speed challenges and reveals backup best practices.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
c++ how to tell if the progra is ctl or mfc atl ect 6 77
mixing C++ & C# in Vis Studio 2013 7 172
Safe conversion? 4 67
Copy output image from TWindowsMediaPlayer 6 41
Often, when implementing a feature, you won't know how certain events should be handled at the point where they occur and you'd rather defer to the user of your function or class. For example, a XML parser will extract a tag from the source code, wh…
What is C++ STL?: STL stands for Standard Template Library and is a part of standard C++ libraries. It contains many useful data structures (containers) and algorithms, which can spare you a lot of the time. Today we will look at the STL Vector. …
The viewer will learn how to use the return statement in functions in C++. The video will also teach the user how to pass data to a function and have the function return data back for further processing.
The viewer will be introduced to the member functions push_back and pop_back of the vector class. The video will teach the difference between the two as well as how to use each one along with its functionality.

772 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