Home > Archive > Clipper > March 2004 > start windows app from clipper
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
start windows app from clipper
|
|
| Thomas Venus 2004-03-26, 10:59 pm |
| Hi All,
in my clipper app i start a windows app (image viewer) via the blinker
swpruncmd()-function.
That works fine.
The only thing is, the called windows app keeps the focus and the user has
to
switch back to the clipper app manually.
Does anybody know of a solution to get the focus back to the calling clipper
app?
Thanks in advance
Thomas
| |
|
|
| tnhoe 2004-03-26, 10:59 pm |
| "Thomas Venus"
You need to use a batch file :-
:begin
yourclipper.exe
if errorlevel=1 goto :winexe
goto :end
:winexe
yourviewer.exe
goto :begin
:end
In your clipper exe,
- for normal exit : errorlevel(0),return
- for running viewer : errorlevel(1),swpruncmd(),return
| |
| Clifford Wiernik 2004-03-26, 10:59 pm |
| You could also make certain that you run application in a window. Some
applications will return focus. For others, you could write a short
xbase++ or other language application that calls window API to return
focus to your clipper application. I do this for a clipper application
that utilizes a windows application to request a client credit bureau
report. The delphi app was not returning focus and you needed to use
the mouse to reselect the clipper window. So clipper->intermediate
app->windows program and back.
Note the name of the window to return to is different for win9x and
win2000/xp.
tnhoe wrote:
> "Thomas Venus"
>
> You need to use a batch file :-
>
> :begin
> yourclipper.exe
> if errorlevel=1 goto :winexe
> goto :end
>
> :winexe
> yourviewer.exe
> goto :begin
>
> :end
>
>
> In your clipper exe,
> - for normal exit : errorlevel(0),return
> - for running viewer : errorlevel(1),swpruncmd(),return
>
>
>
>
|
|
|
|
|