![]() |
FindComponent...
Warum bekomme ich bei folgenden Anweisungen bei TCaption... immer "[Fehler] eingabe.pas(231): Record, Objekt oder Klassentyp erforderlich"?
(CP ist ein weiteres Formular; User ist ein Record-Array)
Delphi-Quellcode:
for i := 1 to 15 do
begin TCaption(FindComponent('CP.Edit'+IntToStr(i))).Text := User[i].name; end; //for-end |
Re: FindComponent...
Vielleicht gehts ja so besser:
Delphi-Quellcode:
oder so:
(Findcomponent('Edit1') as Tedit).Text := 'Hallo';
Delphi-Quellcode:
Tedit(Findcomponent('Edit1')).Text := 'Hallo';
|
Re: FindComponent...
Danke, die erste Variante scheint zu funktionieren :-D
|
Alle Zeitangaben in WEZ +1. Es ist jetzt 05:54 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