Delphi-PRAXiS

Delphi-PRAXiS (https://www.delphipraxis.net/forum.php)
-   Sonstige Fragen zu Delphi (https://www.delphipraxis.net/19-sonstige-fragen-zu-delphi/)
-   -   Delphi Listview EAccessViolation (https://www.delphipraxis.net/95480-listview-eaccessviolation.html)

user.x3m 7. Jul 2007 10:59


Listview EAccessViolation
 
Zitat:

---------------------------
Benachrichtigung über Debugger-Exception
---------------------------
Im Projekt Project1.exe ist eine Exception der Klasse EAccessViolation mit der Meldung 'Access violation at address 004F7AAC in module 'Project1.exe'. Read of address 00000008' aufgetreten.
---------------------------
Anhalten Fortsetzen Hilfe
---------------------------
Zitat:

---------------------------
Project1
---------------------------
Access violation at address 004F7AAC in module 'Project1.exe'. Read of address 00000008.
---------------------------
OK
---------------------------

Hallo,
Also ich rufe bei Doppelklick auf ein Listview item eine Procedure auf, das klapp auch wunderbar.
Die meldung kommt nun, wenn ich nicht auf ein item in der Liste Klicke sondern direkt auf die Listbox, z.b. unten ins schwarze, also unter dem Letztem item in der liste.
Gibt es eine möglichkeit diese zu umgehen?
Danke im Vorraus


Edit:(http://qc.borland.com/wc/qcmain.aspx?da=422)
Gelöst mit. (Workaround)
Delphi-Quellcode:
 for abx := ListView1.Items.Count-1 downto 0 do
  if ListView1.Items[abx].Selected then begin
[...]
end;

TheReaper 7. Jul 2007 11:20

Re: Listview EAccessViolation
 
oder am Anfang vom OnClick, OnSelect ... Ereigniss:
Delphi-Quellcode:
if ListView1.Selected <> nil then exit;
Ist schneller, weil keine Schleife benötigt wird.

user.x3m 7. Jul 2007 11:49

Re: Listview EAccessViolation
 
Ah, ja das hatt ich eigentlich gesucht ; ) Danke.


Alle Zeitangaben in WEZ +1. Es ist jetzt 11:09 Uhr.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024-2025 by Thomas Breitkreuz