Autor Beitrag
Christian V.
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 311

Win Xp Prof
Turbo Delphi 2005
BeitragVerfasst: Di 11.10.05 16:11 
Hallo, ich möchte ein unsichtbares memo haben un darin ein paar sachen einlesen, also:
ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
procedure TForm1.FormCreate(Sender: TObject);
var
memo:TMemo;
begin

reg:=tregistry.Create;
Reg.RootKey:=HKEY_LOCAL_MACHINE;
Reg.OpenKey('SOFTWARE\Microsoft\Windows\CurrentVersion\Run',false);
memo:=TMemo.Create(); //was kommt da in die Klammer?
reg.GetValueNames(memo.Lines);

reg.free;
end;

Da beim .create beim memo weiss ich nicht was reinsetzen. freue mich auf Antworten.

_________________
Hardware runs the world, software controls the hardware, code generates software - Have You already coded today?
opfer.der.genauigkeit
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 754
Erhaltene Danke: 1



BeitragVerfasst: Di 11.10.05 16:14 
Wenn ich das richtig im Kopf habe, kommt im Konstruktor an dieser Position der Owner (also Besitzer der Komponente) rein.
Da kannst du entweder dein Formular angeben oder einfach nil.

_________________
Stellen Sie sich bitte Zirkusmusik vor.
Narses
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Administrator
Beiträge: 10185
Erhaltene Danke: 1261

W11x64
TP3 .. D7pro .. D10.2CE
BeitragVerfasst: Di 11.10.05 16:15 
Moin!

Ein "unsichtbares Memo"? Also quasi eine StringListe? :wink: Wozu dann ein Control-Objekt nehmen...

cu
Narses
Christian V. Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 311

Win Xp Prof
Turbo Delphi 2005
BeitragVerfasst: Di 11.10.05 16:18 
Danke erstmal für die schnellen Antworten,
Das mit Form1 in der Klammer habe ich schon ausprobiert, doch dann kommt ien Fehler beim reinschreiben.
"Element'' Hat kein Übergeordnetes Fenster" Was nun? Gleiches acuh bei "nil"
Ich werds sonst mal mit ner Stringlist versuchen.

_________________
Hardware runs the world, software controls the hardware, code generates software - Have You already coded today?
opfer.der.genauigkeit
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 754
Erhaltene Danke: 1



BeitragVerfasst: Di 11.10.05 16:43 
Die Lösung heißt Self und dein Memo ist unsichtbar vermute ich mal.

Aber egal, der Vorschlag von Narses beantwortet zwar nicht deine Frage, ist aber der sinnvollere Lösungsansatz. :)

_________________
Stellen Sie sich bitte Zirkusmusik vor.


Zuletzt bearbeitet von opfer.der.genauigkeit am Mi 12.10.05 07:33, insgesamt 1-mal bearbeitet
retnyg
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starofftopic star
Beiträge: 2754

SNES, GB, GBA, CPC, A500, 486/66, P4/3.0HT: NintendOS, AmigaOS, DoS
Delphi 5, Delphi 7
BeitragVerfasst: Di 11.10.05 17:04 
oder du setzt memo.parent := form1

_________________
es gibt leute, die sind genetisch nicht zum programmieren geschaffen.
in der regel haben diese leute die regel...