fngb__put_code - Insert Chunks of Code or Data into a .gbf String
Syntax
def fngb__put_code(gb__win_id$,gb__ctl_id$,gb__event_code$,
gb__gbf_data$,gb__sub_name$,gb__sub_code$)
Description
This function is used to insert the following into a .gbf file:
- 
                                                    
Single event handler routines.
 - 
                                                    
Special routines.
 - 
                                                    
User-defined subroutines/functions.
 - 
                                                    
[Program] variable/value lines.
 
| 
                                                             To Insert  | 
                                                        
                                                             Use  | 
                                                        
                                                             Notes  | 
                                                    
| 
                                                             Single event handler routine in the .gbf file  | 
                                                        
                                                             n = fngb__put_code If sub_name$="", it will be formatted as follows: gb__sub_name$="W"+gb__win_id$;  | 
                                                        
                                                             n = 1 if the routine was added, 0 if updated. All "." in gb__sub_name$ will be converted to "_". This is to handle child window IDs in gb__win_id$; they can be formatted like "1.10", "1.10.10", etc.  | 
                                                    
| 
                                                             Special routine (Init, EOJ) into the .gbf file  | 
                                                        
                                                             n = fngb__put_code("", "Init","",gb__gbf_data$,  | 
                                                        
                                                             n = 1 if the routine was added, 0 if updated.  | 
                                                    
| 
                                                             User-defined subroutine or function into the .gbf file  | 
                                                        
                                                             n = fngb__put_code("",  | 
                                                        
                                                             n = 1 if the routine was added, 0 if updated.  | 
                                                    
| 
                                                             [Program] variable/value line into the .gbf file  | 
                                                        
                                                             n = fngb__put_code("",  | 
                                                        
                                                             n = 1 if the variable was added, 0 if updated.  |