2

I'm showing a sfl screen in my rpg program, in one field WPROV, I'm using F4=Help, if the user type F4, the program shows a sfl window help, but the program erase the old and main screen and I only can see the help sfl screen. How can I put in the screen the main screen and the sfl window help screen? another thing I'm checking the fields in the screen in my rpg program, if there is an error I turn on *IN71, *IN72, but I can't see the message error on my screen, why?

Here is the main screen:

A*%%EC                                                                        
A                                      DSPSIZ(24 80 *DS3)                     
A          R W1                                                               
A*%%TS  SD  20130821  124511  ALCRUZ      REL-V7R1M0  5770-WDS                
A                                      TEXT('ventana para ver detalles')      
A                                      CF03(03 'salir')                       
A                                      CF05(05 'ACTUALIZAR')                  
A                                      CF04(04 'AYUDA')                       
A                                      CF06(06 'PROCEDER')                    
A                                      CF12(12 'CANCELAR')                    
A                                      KEEP                                   
A                                      BLINK                                  
A                                      ALARM                                  
A                                      OVERLAY                                
A                                      WINDOW(2 2 18 75 *NORSTCSR)            
A                                      WDWBORDER((*DSPATR HI RI) (*CHAR '.-   
A                                      ..:::.:'))                             
A                                      RMVWDW                                 
A                                      USRRSTDSP                              
A                                  1 22'ACME, S.A. de C.V.'   
A                                      DSPATR(HI)                           
A                                      DSPATR(RI)                           
A                                 16  2'F3=Salir'                           
A                                      DSPATR(HI)                           
A                                  1 63DATE                                 
A                                      EDTCDE(Y)                            
A                                  2 63TIME                                 
A                                  1  2USER                                 
A            PGMA          10A  O  2  2                                     
A                                 16 39'F5=Actualizar'                      
A                                      COLOR(WHT)                           
A                                 16 57'F12=Cancelar'                       
A                                      COLOR(WHT)                           
A                                  2 19'Generación de Ventas Proveedores F- 
A                                      .F.S.'                               
A                                  7 26'No. de proveedor (F4).:'            
A                                 10 26'Fecha Inicial(AAAAMMDD)'            
A                                 13 26'Fecha Final..(AAAAMMDD)'            
A            WFI            8Y 0B 10 51EDTWRD('    /  /  ')                 
A                                      COLOR(YLW)                           
A  72                                  ERRMSG('** Error en Fecha Inicial *- 
A                                      *' 72)                               
A            WFF            8Y 0B 13 51EDTWRD('    /  /  ')                 
A                                      COLOR(YLW)                           
A  73                                  ERRMSG('** Error en Fecha Final **'- 
A                                       73)                                 
A            WNOMBP        30A  O  8 26                                     
A                                 16 13'F4=Ayuda'                           
A                                      COLOR(WHT)                           
A            WPROV          4A  B  7 51COLOR(YLW)                           
A  71                                  ERRMSG('ERROR ESTE PROVEEDOR NO EXI- 
A                                      STE' 71)                             
A                                 16 24'F6=Proceder'                        
A                                      COLOR(WHT)                           

And the sfl window screen is:

A*%%EC                                                                 
A                                      DSPSIZ(24 80 *DS3)              
A          R SWCCHK03                  SFL                             
A*%%TS  SD  20130819  102201  ALCRUZ      REL-V7R1M0  5770-WDS         
A            S0AVAL         1Y 0H      SFLCHCCTL                       
A            S0OPTN        20A  O  6  1                                
A          R SWCCHK04                  SFLCTL(SWCCHK03)                
A*%%TS  SD  20130819  104010  ALCRUZ      REL-V7R1M0  5770-WDS         
A                                      SFLSIZ(0006)                    
A                                      SFLPAG(0005)                    
A                                      WINDOW(*DFT 13 32)              
A                                      OVERLAY                         
A  27                                  SFLDSP                          
A N28                                  SFLDSPCTL                       
A  28                                  SFLCLR                          
A  29                                  SFLEND                          
A                                      CF12(12)                        
A                                      SFLSNGCHC(*RSTCSR *AUTOSLT)     
A*                                                                       
A            SFLRRN         4S 0H      SFLRCDNBR(CURSOR)                 
A                                  1 10'PANTALLA DE AYUDA'               
A                                      COLOR(YLW)                        
A                                  4  1'Selecciona rengón,oprimiendo la' 
A                                      COLOR(WHT)                        
A            CHOICE        20A  O  3  1COLOR(BLU)                        
A                                  5  1'Barra espaciadora, F12= Salir'   
A                                      COLOR(WHT)                        
Meryovi
  • 6,121
  • 5
  • 42
  • 65

1 Answers1

3

In the second display file, add a record format with the ASSUME keyword. You don't need to do anything with it in your RPG program, just define it.

 A          R DUMMY
 A                                      ASSUME
 A                                  1  2' '

As for ERRMSG not working, it's because of RMVWDW. See the DDS Reference for ERRMSG - Restrictions and notes.

  • When the RMVWDW keyword is active, error messages are not displayed.
Buck Calabro
  • 7,558
  • 22
  • 25