Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Visual C++ Question

Status
Not open for further replies.

otto77

Programmer
Mar 4, 2003
3
0
0
US
I'm not exactly sure how to describe this problem...

In Microsoft Visual C++ (version 6), when you start a new project from scratch, it seems like the program will "remember" all of your classes, functions, members, etc.. - and will offer up hints as you are typing.

So..say you have a function defined:

void Function(int a);

Then whereever you are coding, when you type "Function(" - the program will show a litte pop-up box containing the definition of the function.

Or...if you have a struct:

struct MY_STRUCT
{
int a;
int b;
int c;
};

and then you declare a member variable of that struct type:

MY_STRUCT m_MyStruct;

When you start typing: "m_MyStruct." - the program will show a pop-up box showing all of the members available in that struct.

So..here's my problem:

I reaaallly like this little feature of the program, but I do a lot of cutting and pasting between projects, and it seems that after a certain point, the program will stop doing it for me. So..how can I get this to continue?

I hope that I have explained this well enough for people to know what I'm talking about.

Thanks!


 
Well there are certain syntax issues that cause it (auto complete) to stop functioning properly.

Also there is the .ncb file that can sometimes cause problems. When that occurs you can usually fix the problem by closing your workspace entirely and then deleting the .ncb file from the project directory. Then just load your workspace up again and the file will be rebuilt.

Of course code errors definitely stop AC from working until the error is corrected.

good luck
-pete
 
Palbano is right. This is Microsoft's IntelliSense Technology. The *.ncb file contains the information and associations for your program's class definitions, member functions, member variables, etc... If you delete this file it will automatically regenerate the next time you open the workspace. That should fix your problem. This file can become corrupted from time to time. This is especially likely if you try to move your code from one machine to another, rename files, etc...

Blair Fonville
 
So what happens if you move from home to school? The .ncb file can corrupt? Then what happens...all the syntax pop-ups just stop popping up? Then if you delete it, it will regenerate next time you open it with an uncorrupt ncb file, no?
 
I think the problem is sometime correct for me if I just perform a successful compile. I just make a basic app that doesn't do anything, hit the ol' exclamation point with all of the classes I am going to use included (but not referenced) in the project.

While on the topic, will Intellisense ever work for template classes?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top