9
Table Control using Wizard in Module Pool Programming Pre-requisites: The readers must be able to create a module pool program and they should be familiar with screen programming. Purpose of this tutorial: This is to demonstrate the step by step tutorial of how to make use of table control with wizard, where the developer’s effort to write code with table control without wizard is avoided. Introduction: Table control with wizard is the control provided by SAP, in which the users are not needed to code separately for table control operations. It generates automatically system generated code for the following table control operations. 1. Insertion 2. Deletion 3. Scrolling 4. First 5. Last 6. Next 7. Previous 8. Select 9. Select all 10. Deselect 11. Deselect all Step 1: Create an internal table and work area, which we are going to deploy in table control.

Table Control using Wizard in Module Pool Programming

Embed Size (px)

Citation preview

Page 1: Table Control using Wizard in Module Pool Programming

Table Control using Wizard in Module Pool Programming

Pre-requisites:  

The readers must be able to create a module pool program and they should be familiar with screen programming.  

Purpose of this tutorial:  

This is to demonstrate the step by step tutorial of how to make use of table control with wizard, where the developer’s effort to write code with table control without wizard is avoided.  

Introduction:  

Table control with wizard is the control provided by SAP, in which the users are not needed to code separately for table control operations. It generates automatically system generated code for the following table control operations.  

1. Insertion 2. Deletion 3. Scrolling 4. First 5. Last 6. Next 7. Previous 8. Select 9. Select all 10. Deselect 11. Deselect all  

Step 1: Create an internal table and work area, which we are going to deploy in table control.  

 

Step 2: Create a screen called ‘9000’.  

Page 2: Table Control using Wizard in Module Pool Programming

 

Input the screen number as 9000.  

 

Fill up the screen attribute values.

Page 3: Table Control using Wizard in Module Pool Programming

Step 3: Go to the layout of the screen, where you can find the table control with wizard. Drag and drop the table control with wizard to the layout of the screen.  

 

Once you drag and drop the control a popup will appear.  

 

Press Continue. In the next screen enter the table control name as ‘TBC_9000’ or your own name.  

Page 4: Table Control using Wizard in Module Pool Programming

In the next screen you input the internal table and work area which has been created earlier.  

Note: Before it is done, you must activate the page, in which you have declared the internal table and work area. Then only this table control screen will take its properties.

The next screen will automatically retrieve the fields available in the internal table and show. We have to select those fields, which and all should be displayed in table control.

Page 5: Table Control using Wizard in Module Pool Programming

If you have declared any character field for table control line selection, that should not be selected in this screen.  

Select the input/output attributes as ‘Input control’ and give the field for selection of table control rows. Select the multiple line selection.  

Click on Continue. The table control with auto generated code will automatically be created.  

Page 6: Table Control using Wizard in Module Pool Programming

This will automatically create PBO & PAI modules for table control operations.  

Page 7: Table Control using Wizard in Module Pool Programming

 

Step 4: For testing this tutorial, write a simple query to populate the internal table of table control and test the input controls associated with it.  

 

The expected output will be like  

Page 8: Table Control using Wizard in Module Pool Programming

 

Summary :  

As a result of this tutorial, the user will be able to  

1. Use table control with wizard in module pool programming and 2. Create table control operations with system generated code.