views:

2653

answers:

3

Is there a way to prevent VS2008 creating browse info file files for C++ projects.
I rarely use the class browser and it isn't worth the time it takes to recreate it after every build, especially since it runs even if the build failed.

EDIT - it's also needed for go to declaration/definition

+4  A: 

In the project properties, you will find the browse information under:

Configuration Properties -> C/C++ -> Browse Information

Just tell it not to generate browse information. All it is used for is quickly browsing between code components (like using 'Go to Definition') and so forth. I personally like being able to quickly jump between the components, but if it is adding unnecessary time to your compile don't worry about turning it off.

j0rd4n
Doesn't this control the BSC file ? I don't think it's used for the NCB file.
Adisak
+1  A: 

Try creating a folder with the same name of the ncb file (you'll have to delete the file, of course). I used this trick in the past to prevent intellisense from locking VS2005. You'll lose intellisense, though.

Leandro Oliveira
Creating a read only 0 byte file also works (at least in VS2005)
Rob Walker
It also displays a warning dialog every time you open the project that warns that Intellisense is not available for the project.
Adisak
+3  A: 

There is a registry key for this as well: [HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\9.0\Languages\Language Services\C/C++]

Intellisense ON

"IntellisenseOptions"=dword:00000000

Intellisense OFF

"IntellisenseOptions"=dword:00000007

Intellisense ON - NO Background UPDATE

"IntellisenseOptions"=dword:00000005

More flags are available and you can Control Intellisense through Macros as well.

ISENSE_NORMAL = 0       'normal (Intellisense On)
ISENSE_NOBG = &H1       'no bg parsing (Intellisense Updating Off - although NCB file will be opened r/w and repersisted at shutdown)
ISENSE_NOQUERY = &H2    'no queries (don't run any ISense queries)
ISENSE_NCBRO = &H4      'no saving of NCB (must be set before opening NCB, doesn't affect updating or queries, just persisting of NCB)
ISENSE_OFF = &H7
Adisak