Consultor Eletrônico



Kbase P154180: How to start a client session with an ABL class?
Autor   Progress Software Corporation - Progress
Acesso   Público
Publicação   09/10/2009
Status: Unverified

GOAL:

How to start a client session with an ABL class?

GOAL:

Can I use RUN statement to run an ABL class?

FACT(s) (Environment):

OpenEdge 10.2x
Windows

FIX:

A .cls file or a compiled .cls file cannot be a startup procedure for a client session.
A .p with the following content can be use as a startup procedure.
USING "package.Form1" FROM PROPATH.
USING System.Windows.Forms.Application FROM ASSEMBLY.
DEFINE VARIABLE rTemp AS CLASS Form1 NO-UNDO.
DO ON ERROR UNDO, LEAVE
ON ENDKEY UNDO, LEAVE
ON STOP UNDO, LEAVE
ON QUIT UNDO, LEAVE:

rTemp = NEW Form1 ( ) .

WAIT-FOR System.Windows.Forms.Application:Run ( rTemp ).
END.
IF VALID-OBJECT(rTemp) THEN DELETE OBJECT rTemp NO-ERROR.