Hi everybody,
few days ago I started a Thread about this matter. My problem is that when my Application in Delphi should terminate, the forms are all closed but the process still appears in the Task Manager of Windows.
I use Delphi 7 and Windows XP, and my application comes from the upgrade of another made in Delphi 6. Basicly the only difference between them is that now I use dbExpress and before it ran with BDE.
But the previous version of the application terminated correctly!.
I have tried almost everything, there must be something happening because even with 'Application.Terminate' or 'Halt', the Application continues running!
Also if I write:
'repeat Application.Terminate until Application.Terminated;',
which doesn't make any sense, because I thought that as soon you call Application.Terminate, Application.Terminated swicth to 'True', doesn't it?.
The code for the Delphi Project is as follows:
begin
Application.Initialize;
Application.Run;
InitForm := TInitForm.Create(nil);
try
repeat
if ContinueExecuting then begin
InitForm.Panel.Caption := 'Reseting M2DM Organizer ....';
end else begin
InitForm.Panel.Caption := 'Initiating M2DM Organizer ....';
end;
InitForm.Show;
InitForm.Update;
SMTP_DataModule := TSMTP_DataModule.Create(nil);
ModuloDatos := TModuloDatos.Create(nil);
try
OrganizadorForm := TOrganizadorForm.Create(nil);
try
InitForm.Hide;
OrganizadorForm.ShowModal;
finally
OrganizadorForm.Release;
end;
finally
ModuloDatos.Free;
SMTP_DataModule.Free;
end;
InitForm.Hide;
until not ContinueExecuting;
finally
InitForm.Release;
end;
// Halt; or Application.Terminate; here seem to not be working!
end.
I use dbExpress(TClientDataSet) with TDataSetProvider. The Application uses 18 tables (some of them very large) and for each table there is a TDataSource, a TClientDataSet, a TDataSetProvider and a TSQLDataSet.
The previous version managed only TDataSource and TBDEClientDataSet.
Apart from this, the only difference between them is that I need now two functions to manage Autoincrement fields when inserting new rows in two of the tables.
With all this information, has anybody got any clue, why this is happening to me?
Any suggestions are welcome!
Thank you very much,
Nurya ;-)
few days ago I started a Thread about this matter. My problem is that when my Application in Delphi should terminate, the forms are all closed but the process still appears in the Task Manager of Windows.
I use Delphi 7 and Windows XP, and my application comes from the upgrade of another made in Delphi 6. Basicly the only difference between them is that now I use dbExpress and before it ran with BDE.
But the previous version of the application terminated correctly!.
I have tried almost everything, there must be something happening because even with 'Application.Terminate' or 'Halt', the Application continues running!
Also if I write:
'repeat Application.Terminate until Application.Terminated;',
which doesn't make any sense, because I thought that as soon you call Application.Terminate, Application.Terminated swicth to 'True', doesn't it?.
The code for the Delphi Project is as follows:
begin
Application.Initialize;
Application.Run;
InitForm := TInitForm.Create(nil);
try
repeat
if ContinueExecuting then begin
InitForm.Panel.Caption := 'Reseting M2DM Organizer ....';
end else begin
InitForm.Panel.Caption := 'Initiating M2DM Organizer ....';
end;
InitForm.Show;
InitForm.Update;
SMTP_DataModule := TSMTP_DataModule.Create(nil);
ModuloDatos := TModuloDatos.Create(nil);
try
OrganizadorForm := TOrganizadorForm.Create(nil);
try
InitForm.Hide;
OrganizadorForm.ShowModal;
finally
OrganizadorForm.Release;
end;
finally
ModuloDatos.Free;
SMTP_DataModule.Free;
end;
InitForm.Hide;
until not ContinueExecuting;
finally
InitForm.Release;
end;
// Halt; or Application.Terminate; here seem to not be working!
end.
I use dbExpress(TClientDataSet) with TDataSetProvider. The Application uses 18 tables (some of them very large) and for each table there is a TDataSource, a TClientDataSet, a TDataSetProvider and a TSQLDataSet.
The previous version managed only TDataSource and TBDEClientDataSet.
Apart from this, the only difference between them is that I need now two functions to manage Autoincrement fields when inserting new rows in two of the tables.
With all this information, has anybody got any clue, why this is happening to me?
Any suggestions are welcome!
Thank you very much,
Nurya ;-)