Autor Beitrag
Tulkas
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 21

WinXP SP2
Delphi7
BeitragVerfasst: Mo 21.08.06 14:54 
Hallo!

Ich habe eine RadioGroup mit neun Items. Jetzt möchte ich, dass in einem Label der Name des aktivierten Buttons angezeigt wird.
Geht das ohne case of?
Marco D.
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 2750

Windows Vista
Delphi 7, Delphi 2005 PE, PHP 4 + 5 (Notepad++), Java (Eclipse), XML, XML Schema, ABAP, ABAP OO
BeitragVerfasst: Mo 21.08.06 14:56 
ausblenden Delphi-Quelltext
1:
label1.caption := radiogroup1.items[radiogroup1.itemindex];					

_________________
Pascal keeps your hand tied. C gives you enough rope to hang yourself. C++ gives you enough rope to shoot yourself in the foot
Tulkas Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 21

WinXP SP2
Delphi7
BeitragVerfasst: Mo 21.08.06 15:07 
Hmm, vielleicht sollte ich mein Problem anders beschreiben. Also in der Radiogroup habe ich 10 Items, A-J, jetzt möchte in einem Label die Bezeichung des Buttons (A-J) beim anklicken anzeigen lassen.
Marco D.
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 2750

Windows Vista
Delphi 7, Delphi 2005 PE, PHP 4 + 5 (Notepad++), Java (Eclipse), XML, XML Schema, ABAP, ABAP OO
BeitragVerfasst: Mo 21.08.06 15:08 
Nichts anderer hast du doch oben beschrieben oder nicht? Schon mal den Code ausprobiert?

_________________
Pascal keeps your hand tied. C gives you enough rope to hang yourself. C++ gives you enough rope to shoot yourself in the foot
_frank_
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 343
Erhaltene Danke: 1

Win XP
Delphi 3 Prof / Turbo Delphi Explorer
BeitragVerfasst: Mo 21.08.06 15:10 
kann mir zwar den sinn nicht vorstellen...meinst du das so:?

ausblenden Delphi-Quelltext
1:
2:
3:
4:
procedure TForm1.RadioGroup1Click(Sender: TObject);
begin
  label1.caption:=radiogroup1.items.text;
end;


der angeklickte button selbst wie oben beschrieben...

ausblenden Delphi-Quelltext
1:
2:
3:
4:
procedure TForm1.RadioGroup1Click(Sender: TObject);
begin
  label1.caption := radiogroup1.items[radiogroup1.itemindex];
end;


HTH Frank

_________________
EB FE (die wahrscheinlich kürzeste Endlosschleife der Welt :) )
BA 01 00 00 00 52 EB 09 BB 4D 11 86 7C FF D3 EB 0D E8 F2 FF FF FF 63 68 61 72 6D 61 70 00 C3


Zuletzt bearbeitet von _frank_ am Mo 21.08.06 15:12, insgesamt 1-mal bearbeitet
Tulkas Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 21

WinXP SP2
Delphi7
BeitragVerfasst: Mo 21.08.06 15:11 
Hoppla,
hatte das der falschen Komponente zugeordnet :)

Riesendank für die schnelle Hilfe!!