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 IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Code completion with MS Visual C++

Status
Not open for further replies.

ikramk01

Programmer
Jul 21, 2003
2
US
Hi!
I am using QT library code to design UI's using Visual C++ 6.0. I want to get Intellisense to work with the library code so that its easier for me to code. Intellisense is working with standard C++ libs but not with third party libs.
Any ideas?
Thanks
ikramk
 
I think that you may need to force Visual C++ to rebuild the file containing this information. Before you do this make sure that you have included the path and library name for your 3rd pary library in your project options.

Close your application's workspace and delete the following files from my application's directory to correct the problem. You probably only need to delete one of the files, however I do not recall which one.

*.aps, *.ncb, *.pld, *.opt, *.clw

where * will be your application's name.

When you open the workspace, Visual C++ will reconstruct these files and the intellisense for your new library should be added.

Hope this helps.
 
For intellisense to display class and structure members, it needs to read their declaration inside header files and for function prototypes it needs the actual function source code. But the function prototyping for my own functions only works within workspace scope, even if I put them in INCLUDE and SOURCE directories specified inside the VC options.

What could be the reason that intellisense works with prototypes of the standard library, (while not all source is on the system), is that I once saw a *.ncb file for them somewhere in the system, maybe in the common directories?. But I'm not totally sure about this. But if this is the case, than it is a shame that intellisense in VC6 doesn't come with a kind of directable compiler to make the information it needs; Intellisense is wonderfull when it works, but a bit too limited in the config area.

When Intellisense is confused you can try delete the *.ncb file in the workspace root.
 
Hi!
I will try that when i get back to work but i googled on intellisense and came across Visual assist 6.0 Its does exactly what i was looking for. It does statement completions ( if, for , while ) parenthesis matching, code completion, code generation and everything.
The tool is not free but comes with a 30-day trial period. Its like an enhancement to Intellisense.
I agree with you on intellisense tho, its a wonderful tool altho it gets confused. ( Just like if i write more than 3 lines of STL code in Visual C++ 6.0 ( without the service pack) it takes it as an insult and throws some thousand lines of myterious errors and warning. (even with #pragmas to disable them )
Thanks for ur input
ikramk
 
I had a very similar problem: I had to use some third party library (.lib), included all header-files but was still unable to use IntelliSense - the function's parameter info did not pop up. :(

I found this by crawling almost the whole internet for a solution! Maybe it helps somebody, who had the same problem as me.

Try this simple workaround to enable IntelliSense for all headers:

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top