Dynamic text in adobe form – content flow to next page. SAP

Introduction:

I had a requirement from the client which requires an adobe form with dynamic text i.e text content should overflow to next pages. So, we implemented the sub form.

A sub form is a section in the form design that provides anchoring, layout, and geometry management for objects. The object in a sub form can be arranged in rows, columns or some other kind of balanced arrangement.

More than one sub form can be used in a form design. Sub forms can be placed inside other sub form. This relationship is displayed in the Hierarchy palette.

In the Hierarchy palette each sub form is denoted by a node and the objects wrapped in a sub form is displayed under the sub form node. The children of the sub form do not inherit changes made on the sub form level. Each sub form properties are independent of each other.

The below is the process of creating a sub form with text content flowed to next pages.

Step-1:

Firstly, we need to create an interface and provide the required details.

SAP ABAP Development, SAP ABAP Exam, SAP ABAP Exam Prep, SAP ABAP Tutorial and Materials, SAP ABAP Certification, SAP ABAP Preparation

We need to provide description and interface type.

SAP ABAP Development, SAP ABAP Exam, SAP ABAP Exam Prep, SAP ABAP Tutorial and Materials, SAP ABAP Certification, SAP ABAP Preparation

Step-2:
Here, we need to develop the interface according to the requirement. Firstly, we go with the types declaration.

SAP ABAP Development, SAP ABAP Exam, SAP ABAP Exam Prep, SAP ABAP Tutorial and Materials, SAP ABAP Certification, SAP ABAP Preparation

We need to define the importing parameter.

SAP ABAP Development, SAP ABAP Exam, SAP ABAP Exam Prep, SAP ABAP Tutorial and Materials, SAP ABAP Certification, SAP ABAP Preparation

We need to define global data.

SAP ABAP Development, SAP ABAP Exam, SAP ABAP Exam Prep, SAP ABAP Tutorial and Materials, SAP ABAP Certification, SAP ABAP Preparation

We need to implement the required logic in code initialization.

SAP ABAP Development, SAP ABAP Exam, SAP ABAP Exam Prep, SAP ABAP Tutorial and Materials, SAP ABAP Certification, SAP ABAP Preparation

Step-3:
Here in we need to develop an adobe form.

SAP ABAP Development, SAP ABAP Exam, SAP ABAP Exam Prep, SAP ABAP Tutorial and Materials, SAP ABAP Certification, SAP ABAP Preparation

Provide description and interface as seen below.

SAP ABAP Development, SAP ABAP Exam, SAP ABAP Exam Prep, SAP ABAP Tutorial and Materials, SAP ABAP Certification, SAP ABAP Preparation

Step-4:
Here, we need to develop the layout for the adobe form in the layout section. So, I created a table with respect to requirement.

SAP ABAP Development, SAP ABAP Exam, SAP ABAP Exam Prep, SAP ABAP Tutorial and Materials, SAP ABAP Certification, SAP ABAP Preparation

Step-5:
Here, we need to select the page 1(Untitled sub form page 1) in the hierarchy section and in right and in the object section in the left we need to change the option to “Flowed” in the content section and we should make sure that the check box “Allow page break with content” is checked.

SAP ABAP Development, SAP ABAP Exam, SAP ABAP Exam Prep, SAP ABAP Tutorial and Materials, SAP ABAP Certification, SAP ABAP Preparation

Step-6:
Here, we need to select the table in the hierarchy and in the object section we need to make sure that “Allow page break with content” is checked.

SAP ABAP Development, SAP ABAP Exam, SAP ABAP Exam Prep, SAP ABAP Tutorial and Materials, SAP ABAP Certification, SAP ABAP Preparation

Output:
Please find the output below.
Page-1

SAP ABAP Development, SAP ABAP Exam, SAP ABAP Exam Prep, SAP ABAP Tutorial and Materials, SAP ABAP Certification, SAP ABAP Preparation

Page-2

SAP ABAP Development, SAP ABAP Exam, SAP ABAP Exam Prep, SAP ABAP Tutorial and Materials, SAP ABAP Certification, SAP ABAP Preparation

Page-3

SAP ABAP Development, SAP ABAP Exam, SAP ABAP Exam Prep, SAP ABAP Tutorial and Materials, SAP ABAP Certification, SAP ABAP Preparation

Page-4

SAP ABAP Development, SAP ABAP Exam, SAP ABAP Exam Prep, SAP ABAP Tutorial and Materials, SAP ABAP Certification, SAP ABAP Preparation

Source: sap.com