Wednesday, April 6, 2011

Using Code Templates

Code Templates

Code templates reduce the time spent for routine coding. New Front-End Editor is required for creating and applying code templates. They are suggested by code hints. The New Front-End editor has a number of predefined code templates. Whenever § symbol appears in code hint, we can insert a predefined template by pressing Ctrl + Enter.

Modification Log

Modification logs are used in various objects like reports and function modules to track the changes made in object. Header modification log are used to highlight features, limitations and history of the changes made with purpose of these changes.

Creation of Code Templates

Step 1: Shift to ABAP New Front-End Editor. Execute transaction code SE38 and reach to Editor.

Step 2: Click on the button “OPTIONS” available at the bottom of the right hand side.

Step 3: Following Pop-up will appear.

Step 4: Go in Code Templates and Press ADD. Below Pop- up will appear for Name and Description of code template.

Step 5: Use Header Modification Log Format, in code window. Refer screen shot for details.

Click Save. Header Modification Log is created.

Step 6: Repeat the same and add *m as next template. Type Name and Description.

Step 7: Type following in code window.

*/..Begin of Modification%Modification Number%


*/..End of Modification%Modification Number%

You can maintain any number of templates in same way.

Use of Code Templates

Step 1: Type *h in Editor.

Step 2: Press Ctrl + Enter.

Step 3: Type *m in Editor.

Step 4: Press Ctrl + Enter.

Step 5: Following Pop-up will appear.

Enter Modification Number. Suppose 05.

Step 6: Press OK. Following Modification log will appear.

No comments:

Tutorials on SAP-ABAP

Adobe Interactive Forms Tutorials

Business Server Pages (BSP)


Web Dynpro for ABAP (Step by step procedure for web dynpro,Tutorials on Web Dynpro,)

ALV Tutorials

Blog Archive