Board index » cppbuilder » Access Violation with TListView only in Windows Classic mode

Access Violation with TListView only in Windows Classic mode


2004-02-07 04:39:52 AM
cppbuilder41
I have a large application that works fine in all versions of Windows,
except for Windows XP when under the "Windows Classic" appearance.
I have a form that worked fine until I added the TListView object, and I get
an access violation error. It doesn't break on a specific line of code.
Project ecs.exe raised exception class EAccessViolation with message 'Access
violation at address 77E778DA in module
'kernel32.dll'. Read of address 150106C6'. Process stopped. Use Step or
Run to continue.
I'd like to migrate to CB6.0, but I'm in 5.0 for now. I've tried to test
this in 6.0 but can't duplicate the problem very easily without migrating
the entire application, which has its own problems. If someone told me that
this problem was fixed in CB6.0, I'll work on moving it.
Any ideas? :(
 
 

Re:Access Violation with TListView only in Windows Classic mode

"Jefferson Shupe" < XXXX@XXXXX.COM >wrote:
Quote
I have a large application that works fine in all versions
of Windows, except for Windows XP when under the "Windows
Classic" appearance.
I recently (this week) read something similar in the delphi
vcl group. It might point you to an answer.
Quote
I have a form that worked fine until I added the TListView
object, and I get an access violation error. It doesn't
break on a specific line of code.
This behavior is also consistant with poor memory management.
In the past I had code that I thought was working until I added
a seemingly innaquiouse bit of code that resulted in my error
manifesting it's self as an AV.
Check all of your allocations and deallocations. Match up new's
with delete's and new[]'s with delete[]'s. Make sure that you're
not writing (or reading) past the end of any allocated buffers.
Make sure that you're not accessing an object before it's been
created or after it's been destroyed and don't use the OnCreate
or OnDestroy events unless you're absolutely sure of what you're
doing.
www.bcbdev.com/articles/suggest.htm
Quote
I'd like to migrate to CB6.0, but I'm in 5.0 for now. I've
tried to test this in 6.0 but can't duplicate the problem
very easily without migrating the entire application, which
has its own problems.
This statement seems to support an assumption of poor design.
Quote
If someone told me that this problem was fixed in CB6.0,
I'll work on moving it.
No version of BCB natively supports XP.
~ JD
 

Re:Access Violation with TListView only in Windows Classic mode

I am having the exact same problem. Is this something new within Windows
XP? I am thinking of moving to 6.0
The access violation happens everywhere I used the TListView control.
I found reference to it on the internet at:
www.swissdelphicenter.ch/de/showcode.php
This fix did nothing for me. Perhaps you can try it and see if it works for
you?
Thanks,
Joel Decker
www.iclinks.com
--
JOEL DECKER
"JD" < XXXX@XXXXX.COM >wrote in message
Quote

"Jefferson Shupe" < XXXX@XXXXX.COM >wrote:
>I have a large application that works fine in all versions
>of Windows, except for Windows XP when under the "Windows
>Classic" appearance.

I recently (this week) read something similar in the delphi
vcl group. It might point you to an answer.

>I have a form that worked fine until I added the TListView
>object, and I get an access violation error. It doesn't
>break on a specific line of code.

This behavior is also consistant with poor memory management.
In the past I had code that I thought was working until I added
a seemingly innaquiouse bit of code that resulted in my error
manifesting it's self as an AV.

Check all of your allocations and deallocations. Match up new's
with delete's and new[]'s with delete[]'s. Make sure that you're
not writing (or reading) past the end of any allocated buffers.
Make sure that you're not accessing an object before it's been
created or after it's been destroyed and don't use the OnCreate
or OnDestroy events unless you're absolutely sure of what you're
doing.

www.bcbdev.com/articles/suggest.htm

>I'd like to migrate to CB6.0, but I'm in 5.0 for now. I've
>tried to test this in 6.0 but can't duplicate the problem
>very easily without migrating the entire application, which
>has its own problems.

This statement seems to support an assumption of poor design.

>If someone told me that this problem was fixed in CB6.0,
>I'll work on moving it.

No version of BCB natively supports XP.

~ JD

 

{smallsort}