Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. Data members

Data members

Scheduled Pinned Locked Moved C / C++ / MFC
c++help
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J Offline
    J Offline
    jpyp
    wrote on last edited by
    #1

    Hi! One of my include file used to be like this: my_include.h struct tagInfo { int a; int b; } stInfo; Then I added the element c: struct tagInfo { int a; int b; int c; } stInfo; My program goes something like this: #include "my_include.h" MyProg () { // somewhere in my code CString string1.Format("%d", stInfo.a); CString string2.Format("%d", stInfo.c); } In the string#.Format statement, when I type the . after stInfo, VC++ open a popup window with a list of all elements included in the structure stInfo. That list still shows a and b only. The element c is not showed but it compiles properly. I know I have the right file because if I change the element a to z in my include file, then the code does not compile because a is not a member of stInfo. I guess I need to refresh something but I don't know what. Thanks for your help.

    jpyp

    G 1 Reply Last reply
    0
    • J jpyp

      Hi! One of my include file used to be like this: my_include.h struct tagInfo { int a; int b; } stInfo; Then I added the element c: struct tagInfo { int a; int b; int c; } stInfo; My program goes something like this: #include "my_include.h" MyProg () { // somewhere in my code CString string1.Format("%d", stInfo.a); CString string2.Format("%d", stInfo.c); } In the string#.Format statement, when I type the . after stInfo, VC++ open a popup window with a list of all elements included in the structure stInfo. That list still shows a and b only. The element c is not showed but it compiles properly. I know I have the right file because if I change the element a to z in my include file, then the code does not compile because a is not a member of stInfo. I guess I need to refresh something but I don't know what. Thanks for your help.

      jpyp

      G Offline
      G Offline
      Gary R Wheeler
      wrote on last edited by
      #2

      If you are using Visual C++ 6, Visual Studio .NET (2002), or Visual Studio .NET 2003, the IntelliSense file has gotten corrupted. This file has the extension .ncb, and will have the same name as your project file. Exit Studio, delete the .ncb file, and it will be recreated automatically when you open the project again. Visual Studio 2005/2008 may use the same thing, but I don't use them regularly so I don't know for sure.

      Software Zen: delete this;
      Fold With Us![^]

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups