hmm hab das ganze jetzt mit dieser function hier gelößt, etwas provisorisch aber es läuft
Also mit einer neuen Form die angezeigt und wieder geschlossen wird.
1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19: 20: 21: 22: 23: 24: 25: 26: 27: 28: 29: 30: 31: 32: 33: 34: 35: 36: 37: 38: 39: 40: 41: 42: 43: 44: 45: 46:
| function TForm_PEP__Main.LoadData: Boolean; var FrmStatus : TForm_Status; WindowList : Pointer; begin Result:= False;
try FrmStatus:= TForm_Status.Create(NIL);
try WindowList:= DisableTaskWindows(frmStatus.Handle); try FrmStatus.Show;
Repeat FrmStatus.Caption := 'Lade Daten'; FrmStatus.Label1.Caption:= 'Daten 1'; Application.ProcessMessages; FrmStatus.Label1.Caption:= 'Daten 2'; Application.ProcessMessages; break; until False; finally EnableTaskWindows(WindowList); FrmStatus.Hide; end; finally FrmStatus.Free; end; except end; end; |
bsp:
Delphi-Quelltext
1: 2: 3: 4: 5: 6: 7:
| FrmStatus.sProgressbar1.Min := 0; FrmStatus.sProgressbar1.Max := 100; FrmStatus.Label1.Caption:= 'login...'; FrmStatus.Label2.Caption:= '10%'; FrmStatus.sProgressbar1.Position := FrmStatus.sProgressbar1.Position + 10; Application.ProcessMessages; ...usw |
Problem ist halt nur, dass ich die procedure(n) die die listviews füllen in diese function packen muss