• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 307
  • Last Modified:

CListBox InsertString can't be called

I have a dialog with a list box on it; I added a control to it called m_listBox that's a public variable, so others can access it from another class. When I go to use it like so:

//This is being called in another class that creates an object of the dialog that has the list box
m_mydialog.m_listBox.InsertString(.....);

// when I get to typing "m_listBox." I dont' see the system showing me a list of methods available to m_listBox (as it should)....

is there anything wrong in the way I'm using it?
0
jade03
Asked:
jade03
  • 2
  • 2
1 Solution
 
AxterCommented:
Hi jade03,
> >is there anything wrong in the way I'm using it?
No.
Sometimes VC++ will fail to show proper list for your object.
This is a bug in VC++ IDE, and not a problem with your code.

David Maisonave :-)
Cheers!
0
 
AlexFMCommented:
Close VC++, remove project .ncb and .opt files, run VC++ and open project again.
0
 
jade03Author Commented:
AlexFM, I couldn't find the .opt files...
0
 
AxterCommented:
The ability for yoru IDE to list your object's methods is called Intellisense.

Because of the bugs in VC++, I don't use the build-in VC++ Intellisense.
Instead I use a third party application called Visual Assist.  This application adds additional features to VC++.
I highly, highly recommend that you try this tool out.
You can download a trial version from the following link:
http://www.wholetomato.com/

I garantee once you try it, you'll never want to go back.

The Intellisense is much more reliable using the Visual Assist AddOn, compared to VC++ built-in Intellisense.
0
 
jade03Author Commented:
I removed just the .ncb file and restarted the application and it worked!

thanx!
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now