473,397 Members | 1,950 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,397 software developers and data experts.

Where to set the CPP file search path in Visual Studio

Ed
Hi, dear all,
Sometimes, when I debug my program, VS seems very smart to find the
cpp file even if the file was not in the working directory. I am
wondering how did VS try to find the cpp file when we debug program.
Even walking through every menu items, I can not find the related
information.

What's the rules of it? Or, can we set the search path of it?
Jun 27 '08 #1
3 2965
Ed wrote:
Hi, dear all,
Sometimes, when I debug my program, VS seems very smart to find the
cpp file even if the file was not in the working directory. I am
wondering how did VS try to find the cpp file when we debug program.
Even walking through every menu items, I can not find the related
information.

What's the rules of it? Or, can we set the search path of it?
Ed:

The location of every file in your project is recorded in the .vcproj file.

--
David Wilkinson
Visual C++ MVP
Jun 27 '08 #2
Ed wrote:
Hi, dear all,
Sometimes, when I debug my program, VS seems very smart to find the
cpp file even if the file was not in the working directory. I am
wondering how did VS try to find the cpp file when we debug program.
Even walking through every menu items, I can not find the related
information.

What's the rules of it? Or, can we set the search path of it?
The full path to each source file is stored in the PDB file, and that's the
first place the debugger looks for source files. As long as the source
files are accessible using the same paths that the compiler used, the
debugger will be able to find them. Beyond that, you can set up a "source
server" to enable the debugger to pull source files from a central location
if they're not going to be accessible using the build-time paths.

-cd
Jun 27 '08 #3
Ed
On May 5, 9:57 pm, "Carl Daniel [VC++ MVP]"
<cpdaniel_remove_this_and_nos...@mvps.org.nospamwr ote:
Ed wrote:
Hi, dear all,
Sometimes, when I debug my program, VS seems very smart to find the
cpp file even if the file was not in the working directory. I am
wondering how did VS try to find the cpp file when we debug program.
Even walking through every menu items, I can not find the related
information.
What's the rules of it? Or, can we set the search path of it?

The full path to each source file is stored in the PDB file, and that's the
first place the debugger looks for source files. As long as the source
files are accessible using the same paths that the compiler used, the
debugger will be able to find them. Beyond that, you can set up a "source
server" to enable the debugger to pull source files from a central location
if they're not going to be accessible using the build-time paths.

-cd
"The full path to each source file is stored in the PDB file"

Thank you, all !

Ed.
Jun 27 '08 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Anders Eriksson | last post by:
Hello! I'm using VC++ 7.1 and MFC. In a header file that is located in a different directory that the main project I include a header file that is located in the main project directory. The...
3
by: Old Codger | last post by:
Thanks for this Oleg, nice try! Unfortunately the solution you gave refers to .NET 2002 and I am using .NET 2003. In the article it says: "This bug was corrected in Microsoft Visual C++ .NET...
2
by: Andrew Jocelyn | last post by:
Hi I get this error when I change something in the web.config file. When I build the VS projects and load the first web page the application runs fine. If I then make a save the web.config file...
6
by: BookerW | last post by:
Ok interesting, on my local machine And i did not do a good job of keeping track of the exact order.... but on my local machine in which i have vis studio 2003 installed and IIS for win XP,...
3
by: Lou | last post by:
Question: I can't seem to get file.exists(filename) to return true when I search using wildcards, and I know there's a file in that dir with that extension. here's the path dim yesno as...
4
by: Axter | last post by:
Sorry for OT question, but does any one have a working *.bat file to get Comeau to work with VC++ 7.1, VC++ 8.0, or GNU 3.x compilers. I've tried everything I can think off, to get it to work,...
7
by: Nathan Sokalski | last post by:
I am an ASP.NET developer, and Visual Studio 2005 seems to have stopped declaring the controls that I add in the *.designer.vb files, therefore forcing me to manually add them before I can use them...
0
by: =?Utf-8?B?TWFyY2VlcG9v?= | last post by:
I'm a newbie using Visual Studio and Vb.Net. The vbscript below opens a Windows Explorer Search Window. The Windows Explorer Search Window has fields in which the user can insert: (i) a search...
20
by: David Thielen | last post by:
Hi; When we add a reference to a web app, where is that information stored? There is no project file, it's not in the web.config or solution file. ??? - thanks - dave ...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.