Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

visual studio 2012 adding new header file

In Visual Studio 2012 (C++ environment), for a Win32 console application, I need to include a new header file to my project. I tried copying the files in the project's location but that is of no help. The file is iGraphics.h and it is shown in the header files list but does not compile. What should be the correct approach?

enter image description here

like image 525
Nasif Imtiaz Ohi Avatar asked Apr 09 '13 11:04

Nasif Imtiaz Ohi


1 Answers

You should add the path to that header to the additional include directories under C/C++ in your project settings. Afterwards, just #include "iGraphics.h" where you need it.

Don't just move header files around, and don't add existing headers to your project for no good reason. This way, you can easily change versions by just specifying a different folder.

like image 157
Luchian Grigore Avatar answered Oct 03 '22 00:10

Luchian Grigore