Ü  DFT(Default)

·         DFT keyword is used to display the default value on the screen.

·         It’s a field level keyword.

·         If we want to display a constant field then there is no need of mentioning the DFT keyword, it not a mandatory keyword in this case.

·         The syntax for displaying a constant field on the screen is:

DFT(‘constant value’)

Or,

‘Constant value’

·         For input type field, the value mentioned with the DFT keyword is displayed as a default value on the screen; every time the screen is displayed.

·         For output capable and input/output capable fields, we must specify the keyword PUTOVR at the record level and OVRDTA at the field level with the DFT keyword.

·         The DFT keyword is not valid on decimal fields.

 

 

Example

 

>>> Using DFT for constant field

 

 

A                                  5 25DFT('ACC')

Or,

A                                  5 25'ACC'

 

 

>>> Using DFT for input field

 

 

A            S_ACC         12A  I  5 35DFT('A00000000001')  

                                  

 

 

 

 

                             ACCOUNT ENTRY DISPLAY                             

                                                                               

                                                                               

                        ORG       ___                                             

                        ACC       A00000000001                                 

                        CCY       ___                                             

                        PARTY     ____________                               

                                                                               

                                                                               

                                                                               

                                                                               

                                                                               

                                                                                

                                                                               

                                                                               

                                                                                

                                                                               

    F3 = EXIT      F12 = CANCEL                                               

 

                                                                                

                                                                               

>>> Using DFT for input/output field

 

 

A          R HEADER                    PUTOVR                   >>>>>>>>>>>>>> 

A                                  1 30'ACCOUNT ENTRY DISPLAY'   

A                                      DSPATR(HI)                

A                                      COLOR(BLU)                

A                                  4 25'ORG'                      

A                                      DSPATR(HI)                

A                                      COLOR(BLU)                

A            S_ORG          3S 0B  4 35                          

A                                      FLDCSRPRG(S_ACC)          

A  50                                  DSPATR(RI)                

A                                  5 25'ACC'                     

A                                      DSPATR(HI)                

A                                      COLOR(BLU)                

A            S_ACC         12A  B  5 35DFT('A00000000001')        >>>>>>>>>>>>

A                                      OVRDTA                     >>>>>>>>>>>>

 

 

 

 

 

 

                             ACCOUNT ENTRY DISPLAY                             

                                                                               

                                                                               

                        ORG       ___                                             

                        ACC       A00000000001                                 

                        CCY       ___                                             

                        PARTY     ____________                             

                                                                               

                                                                               

                                                                                

                                                                               

                                                                               

                                                                                

 

                                                                               

    F3 = EXIT      F12 = CANCEL        

                                       

 

 

 





User Comments:





Copyright © Go4as400.com, 2013-2016. Copyright notice