das mit showmodal klingt ganz gut. Ich habe nur das Prob, dass nach schliessen des 2. Formulars nicht mehr in meine schleife zurückgekehrt wird, bzw. mir ist unkar wie ich in die schleife reinschreibe dass er fortfahren soll.
Hier einen Auszug aus meinem Code:
Delphi-Quellcode:
...
for j:=1 to AnzahlNeuStoer do
begin
[...]
StoerungsmeldungsfensterErzeugen; //Procedure welche 2. Formular erstellt
[...]
end;
...
und folgendermassen wird das 2. Formular erstellt:
Delphi-Quellcode:
procedure TFormStoerung.StoerungsmeldungsfensterErzeugen;
begin
Application.Initialize;
with TFormStoerung.Create(nil) do
try
Update;
application.CreateForm (TFormStoerungsmeldung, FormStoerungsmeldung);
finally
Free;
end;
Application.Run;
end;