Autor Beitrag
rstaeker
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Beiträge: 94

WIN 2000
D6 Prof
BeitragVerfasst: Mi 13.07.05 21:33 
Hallo,

aus irgendeinem Grund ist das Programm der Meinung, dass es die Ressource nicht finden kann. Hier mal der Quellcode der den Fehler verursacht:
ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
procedure TKFZS_Quick.DataSourceKfzDataChange(Sender: TObject; Field: TField);
begin
    if TableKfzUnfall.AsBoolean = TRUE
     then SpeedButtonUnfall.Glyph.LoadFromResourceName(Parent.Handle,'LED_ON')
     else SpeedButtonUnfall.Glyph.LoadFromResourceName(Parent.Handle,'LED_OFF');
end;
Er meckert immer bei den LoadRessource-Zeilen, ich hab sie auch schon vertauscht.

Habe schon verschiedene Handles ausprobiert:
- Parent.Handle
- Handle
- Self.Handle

Bin ich blöd :-) und übersehe etwas??
Die Ressource ist definitiv vorhanden, ich sehe Sie z.B. mit Reshacker.

Rene
maxk
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 1696
Erhaltene Danke: 1

Win XP, Debian Lenny
Delphi 6 Personal
BeitragVerfasst: Mi 13.07.05 21:40 
Versuch's mal mit HInstance ;)

_________________
Ein Computer wird das tun, was Du programmierst - nicht das, was Du willst.
rstaeker Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starofftopic starofftopic star
Beiträge: 94

WIN 2000
D6 Prof
BeitragVerfasst: Mi 13.07.05 21:45 
user profile iconmaxk hat folgendes geschrieben:
Versuch's mal mit HInstance ;)

Shit, ich wusste daß ich etwas übersehe.

Thx, das war es.