Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How can one leave ShowModal and return to same.

Status
Not open for further replies.

terrytype

Programmer
Jun 1, 2011
97
0
0
ZA
I have Application1 which involves the following

frmAccs := TFrmAccs.Create(nil);
frmAccs.ShowModal;

Within Application1 I trigger Application2 [as follows] to obtain a result for Application1 to further rely upon.

WinExec('c:\Program Files\Application2.exe', SW_SHOW);

...which achieves the required result ....BUT frmAccs.ShowModal loses its focus to produce unwanted result.

To overcome the problem I tried the following ...

frmAccs.Release;
WinExec('c:\Program Files\Application2.exe', SW_SHOW);
frmAccs.Refresh;

...whereby frmAccs.ShowModal [apparently] maintains its proper focus BUT Application1 hangs.

Any suggestions anyone?

Thanks in advance.






Old Man Delphi
 
FIXED!

Problem had nothing to do with modal.

Simple matter of losing relationships between the records.

Old Man Delphi
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top