Kbase P107314: How to use launchContainer to launch a child container in front of the parent.
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  05/08/2005 |
|
Status: Unverified
FACT(s) (Environment):
Dynamics
SYMPTOM(s):
How to use launchContainer to launch a child container in front of the parent.
LaunchContainer launches child container behind parent.
Focus is being applied to the child container and the parent is being moved to bottom, but this does not bring the child into focus.
Dynamics RETURN trigger does not pass focus to the child container because the default behavior keeps focus in the parent fillin.
RETURN NO-APPLY does not work with Dynamics.
CAUSE:
Dynamics does not implement triggers the same way that ADM2 does. Subsequently a RETURN NO-APPLY does not prevent default behavior from occurring. So trying to pass focus to a child window from the return trigger of a parent fillin does not work.
FIX:
Use RETURN ERROR to prevent the default behavior from occurring. For example:
hContainer = DYNAMIC-FUNCTION('GetContainerSource' IN TARGET-PROCEDURE).
WindowHandle = DYNAMIC-FUNCTION('GetContainerHandle' IN hContainer).
RUN launchContainer IN gshSessionManager (
INPUT bpartners_lookupfoldw":U, /* pcObjectFileName */
INPUT "":U, /* pcPhysicalName */
INPUT "":U, /* pcLogicalName */
INPUT FALSE, /* plOnceOnly */INPUT "":U, /* pcInstanceAttributes */
INPUT "":U, /* pcChildDataKey */
INPUT "":U, /* pcRunAttribute */
INPUT "":U, /* container mode */
INPUT hWindowHandle, /* phParentWindow */
INPUT TARGET-PROCEDURE, /* phParentProcedure */
INPUT hContainer, /* phObjectProcedure */
OUTPUT hObject, /* phProcedureHandle */
OUTPUT cProcedureType /* pcProcedureType */
).
WindowHandle:MOVE-TO-BOTTOM().
RETURN ERROR.