Autor Beitrag
Nemo
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 26

Win 2000/WinXP
D7 Prof
BeitragVerfasst: Di 01.03.05 16:53 
Hallo Gemeinde!

Ich bins mal wieder, Euer Nemo :)


Nur eine Kurzfrage, ich habe einen Array of TBitmap erstellt, der meine Anwendung extrem beschleunigen könnte, wenn ich ihn denn hinbekäme. Das Problem ist ich brauche eine Abfrage wie:

ausblenden Quelltext
1:
2:
Wenn TBitmapArray[x] schon exestiert
lade TBitmapArray[x] in Image1


Eine ganz einfache Variante die ich mir ausgedacht habe, ist:

ausblenden Delphi-Quelltext
1:
if TBitmapArray[x] = LeeresBitmap then					


Das funktioniert beim ersten Durchlauf der Bilder 1-9 wunderbar, danach komischer Weise nicht mehr, obwohl keine weiteren Stellen definiert werden :?:
wulfskin
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 1349
Erhaltene Danke: 1

Win XP
D5 Pers (SSL), D2005 Pro, C, C#
BeitragVerfasst: Di 01.03.05 17:03 
so?
ausblenden Delphi-Quelltext
1:
2:
if  (Assigned(BitmapArray[x]))  //wenn nicht nil
and (not BitmapArray[x].Empty)) //und nicht leer
Gruß hape!

_________________
Manche antworten um ihren Beitragszähler zu erhöhen, andere um zu Helfen.
Nemo Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 26

Win 2000/WinXP
D7 Prof
BeitragVerfasst: Di 01.03.05 17:13 
Klingt gut, geht aber leider nicht.

Bei:
ausblenden Delphi-Quelltext
1:
2:
3:
4:
if  (Assigned(PreviewBilder[arrindex+i])
    and (not PreviewBilder[arrindex+i].Empty)) then begin
[..]
end else

[..]
führt er dann immer nur die Else Anweisungen aus.
Nemo Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 26

Win 2000/WinXP
D7 Prof
BeitragVerfasst: Di 01.03.05 17:18 
Pardon mein Fehler. Geht wohl, ich brauchte es ja nur umgekehrt :roll:

ausblenden Delphi-Quelltext
1:
if  (not Assigned(PreviewBilder[arrindex+i])) then begin					


klappt tadellos.

Danke!