Paliss
10th October 2001, 15:30
I'm making program with subprocess, but I cannot return to parent form.
Here is parts of programs of parent and child

Parent:
child.id = activate("tdslso103s000")
export("cpay.dsca", cpay.dsca)
switch.to.process(child.id)
kill(child.id)
import("cpay.dsca", cpay.dsca)

Child:
wait.for.switch()
import("cpay.dsca", cpay.dsca)
actions ...
export("cpay.dsca", cpay.dsca)
switch.to.process(parent)

When child process do switch.to.process(parent), it is sucessfully done.
Program continue in parent process and it is sucessfully killed child process, it isn't in process list yet.
But child form is on the top. I cannot enter in parent form.
Child form is blank gray form. I cannot do anythting with window of form.

Can sombody help me where is my fault?

Thank you for help
Paliss

PS. Can me somebody tell more about processes and working with them. Switching etc.

Thanks
Paliss

Han Brinkman
10th October 2001, 16:37
I don't know exactly how to use these functions, haven't used them myself.

However have you considered using the zoom.to$ function? That handles automaticly the activating etc.
You can use also zoom.from sections to perform specific actions depending on the session it's started from.

You have to export the variable's in the parent before using them in the child program.

Hope it helps you a bit further.

Rgrds,

mark_h
10th October 2001, 23:05
Is your switch.to.process(parent) in the child session in the choice.end.program section of child script? I have only used this once and it works for me.

Good Luck!

Paliss
11th October 2001, 09:38
I use switch.to.process(parent) in following sections:

choice.end.program:
before.choice:
and
choice.abort.program:
before.choice:

mark_h
11th October 2001, 16:04
What type of form and script are the child? The one time I used it set the form like the Baan session I was copying - modal without title. The script was type 1/2/3 with main table. If not this then I am not sure what it could be, like I said I have only used this once or twice.

Good Luck!