Finding list of header files in editor

cancel
Showing results for 
Search instead for 
Did you mean: 

Finding list of header files in editor

4,013 Views
Contributor IV
In the upper left corner of the editor form there is a "h" button.
It will pull down a list of header files included in the particular source file.
It is a convenient way to locate and open a .h file.
 
Now for some reason all I get when I click the "h" is
a message: "Not a project file"
 
Why does this happen, and how do I fix it?
 
Thanks,
Anders J
 
 
 
Labels (1)
0 Kudos
3 Replies

18 Views
Contributor I
I was having the same problem and I found that after adding files to the project I needed to shutdown and restart CW for the ".h" button to work.
0 Kudos

18 Views
NXP Employee
NXP Employee
In the default setup, those entries are filed by the compiler, hence you have to compile it once. Restarting is not necessary.
0 Kudos

18 Views
NXP Employee
NXP Employee
This lookup works by asking the project for the list.
If you open a C file which CW cannot accociate with a project, you get this "Not a project file".
Maybe it should read "this file is not part of any currently open project", but this may be a bit long.

So
- open your project
- add it to your project
- you can also jump to header files by selecting the filename in the #include line, and press Ctrl-D (or the "Find and Open File..." context menu))
- there is a special shortcut to jump between header and implementation file, look it up in Edit->Command and Keybindings ->Miscellaneous->Go to header/source file. (the default keybinding for it does work fine on US keyboards, but not on my local one here. So I do usually change it locally)

Daniel
0 Kudos