Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Error for getitem and insertitem

Posted on 1997-05-20
3
Medium Priority
?
362 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 20 total points
ID: 1163574
Grade your provious responses and maybe someone will help you
0
 
LVL 4

Expert Comment

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

Expert Comment

by:mzbd9w
ID: 2576360
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

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

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…
  Included as part of the C++ Standard Template Library (STL) is a collection of generic containers. Each of these containers serves a different purpose and has different pros and cons. It is often difficult to decide which container to use and …
The goal of the tutorial is to teach the user how to use functions in C++. The video will cover how to define functions, how to call functions and how to create functions prototypes. Microsoft Visual C++ 2010 Express will be used as a text editor an…
The viewer will learn how to use the return statement in functions in C++. The video will also teach the user how to pass data to a function and have the function return data back for further processing.
Suggested Courses

916 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