Solved

Error for getitem and insertitem

Posted on 1997-05-20
3
332 Views
Last Modified: 2012-05-04
I have created the mulit-column list control to show and treat data. When I run the program, the error ' The instruction at "0x10219a5c" referenced memory at "0x2fdf070a". The memory could not be "written".' was prompted. I have debugged the program and discover this error created by getitem and insertitem of CListCtrl.

What is the meaning of this error?
How to fix it?
Thank.
0
Comment
Question by:edward95
  • 2
3 Comments
 
LVL 4

Accepted Solution

by:
md041797 earned 10 total points
Comment Utility
Grade your provious responses and maybe someone will help you
0
 
LVL 4

Expert Comment

by:md041797
Comment Utility
Thanks for grading your responses.  Refuse these answers to re-queue them.  Sorry I was so loud.
0
 

Expert Comment

by:mzbd9w
Comment Utility
One possibility:  We recently started experiencing this problem because we were not setting the mask on the data item before calling GetItem.  I haven't been able to find documentation indicating a need to set the mask; however, that does appear to be our problem.  The weird thing is, it worked when originally implemented.  We didn't have a problem until we started upgrading our OS Service Packs.  Sample code to set mask follows:
LV_ITEM lvi;
lvi.mask = LVIF_IMAGE | LVIF_STATE;
0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

When writing generic code, using template meta-programming techniques, it is sometimes useful to know if a type is convertible to another type. A good example of when this might be is if you are writing diagnostic instrumentation for code to generat…
IntroductionThis article is the second in a three part article series on the Visual Studio 2008 Debugger.  It provides tips in setting and using breakpoints. If not familiar with this debugger, you can find a basic introduction in the EE article loc…
The viewer will learn how to user default arguments when defining functions. This method of defining functions will be contrasted with the non-default-argument of defining functions.
The viewer will learn additional member functions of the vector class. Specifically, the capacity and swap member functions will be introduced.

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now