RE: RE: UDC
First, in S998 (or wherever you get your DD attributes)
You have to include the code (substitute your data field name for xxxx
in the example)
MOVE *BLANK FRDTAI =20
MOVEL'xxxx' FRDTAI =20
CALL 'X9800E' 81
---- -------- =20
PARM I9800E =20
FRERR IFEQ '0' =20
MOVE FRDSCR B@XXXX 40 =20
MOVE FRDTAT T@XXXX 1 =20
MOVE FREC E@XXXX 1 =20
MOVE FRDTAS C@XXXX 40 =20
MOVE FRDTAD G@XXXX 10
MOVE FRCDEC F@XXXX 1=20
MOVELFRSY S@XXXX 4=20
MOVE FRRT R@XXXX 2=20
MOVE FRDVAL D@XXXX 40=20
MOVE FRVAL A@XXXX 40=20
MOVE FRLVAL L@XXXX 40=20
MOVE FRUVAL U@XXXX 40=20
MOVE FREDWR W@XXXX 30=20
MOVE FRLR J@XXXX 1
MOVE FRNNIX N@XXXX 20=20
Z-ADD1 #@XXXX 110=20
MOVE F@XXXX #A =20
DO #A =20
MULT 10 #@XXXX =20
END =20
END =20
=20
What you need to do in your program is determined by how you want to use
the UDC for the data field. How do you want to "apply" the UDC? Get a
text description from what they entered?
MOVELvdXXXX $XXXX 2 =20
MOVELS@XXXX #USY =20
MOVE R@XXXX #URT =20
MOVE *BLANKS #UKY =20
MOVE vdXXXX #UKY =20
MOVE *BLANK VC006 =20
CALL 'X0005 ' 81
---- -------- =20
PARM I0005U =20
MOVE #UERR *IN81 =20
*IN81 IFEQ '0' =20
CLEAR@UA =20
MOVEA#UDL01 @UA =20
Z-ADD25 #OUTLG =20
EXSR C9822 =20
---- ----- =20
MOVEA@UB VC006 =20
END =20
CLEARI0005U =20
=20
If you don't care about following JDE standards, then you can simply
chain to F0005 with the SY, RT and KY values. You can also use the
CHAIN (or SETLL) to simply verify if the value entered on the screen is
a value that is in the UDC.
=20
If the video field is blank, do you want to set the default value? Do
you want to edit their entry for upper & lower limits? Do you want the
UDC to popup on their screen if they press F4? Then you have to use the
code for cursor sensitive help (pick a JDE vanilla program and look at
the example code if you are not familiar with how to code cursor
sensitive help.=20
=20
Do you have JDE's 'Quick Start Application Tool' installed (J93515V)?
This might help you by adding the code that you need automatically. Its
been awhile since I've used it, so I don't remember all the ins and outs
of what it will and won't do. As long as you have the file and video
already created & compiled the way you want, you should be able to use
Quick Start to generate your RPG and CLP. If you want some more info on
Quick Start and how to use it, I think I might have an electronic copy
of a guide we made locally to use it. You can contact me directly
through JDEList.
=20
=20
J Walker
JDE A7.3 cum(mongrel)