Professional Documents
Culture Documents
Before starting this tutorial, please ensure that Adobe life cycle designer is installed on your system and
Adobe designer is configured on your server.
In this tutorial, we would pass a parameter (CARRID) to the form and print the same with a page heading.
Go to transaction SFP.
For every form, an interface is mandatory. Enter the name of the interface and click on Create.
Click on Save. Enter the package and the workbench request no as per the requirements.
Following screen appears:
Double-click on Import.
Following screen, with a default parameter name, appears:
Click on Create.
As shown above, select the radio-button Form and enter the name of the form. Click on
Create.
Enter the description for the Form and also enter the name of the interface created earlier.
Click on Save.
Now enter the package name and the workbench request.
Following screen appears:
Now drag and drop the import parameter Carrid from interface to Context on the right-hand side as shown
below:
Now let us include a heading and display the value of the carrier id passed to this form.
Now click on Palettes Layout (see the screenshot below):
Now in the tab Standard, drag and drop the element Text onto the page.
Now double-click on the object and enter the text required (Page heading here).
Now go to library again (click on Palettes Library) and drag and drop the object Text Field onto the
page.
Now select the object Text Field created just now. Right-click and select Palettes Object.
Go to Transaction SFP->
Select Interface Radio Button & Enter the name to create New Interface.
(Eg:- z_ft).
Save
Check
Enter the Description & Interface name which we have created and press save button.
Drag & drop the Global data form Interface to Context Level & Save the form.
.
Expand the Text Field.
Enter
the
Following
text
Select only Name Text (Which will be highlighted), Right click on it.
in
field.
Go to object tab-> Binding Tab -> Select the Binding and Rename it from {TextField} to {Name}.
SCENARIO 2:
Create an internal table with the same structure defined earlier in TYPES definition as shown below.
Provide the description for the form and interface name created as shown below.
Step9: Here, we have to drag and drop the contents, to be displayed in the layout, from interface to context
as shown below.
Step10: Here in the internal table PT_VBAP, we can de-activate the fields, which we dont want to display
in the layout. We can do this as shown below.
Place the cursor on the field and give a right click. Now select Deactivate.
Step12: Now, Drag and drop the VBELN (Document Number) field to Master page.
Step13: Select the object VBELN. Go to palettes-object. You will get the following screen.
Step14: Now, drag and drop the internal table PT_VBAP from Data View to body page.
In this demo we will create an adobe form which displays text in two different languages (English
or French) based on the given condition. This functionality is achieved by using TEXT MODULES
in adobe forms.
Step1: Go to transaction SFP and create an interface for the Adobe form.
Note: Maintain Interface type ABAP-Dictionary Base interface. (IN ECC6.0 Version)
Step2: Create an import parameter as shown below:
Step4: Now go to transaction Smartforms to create Text Module for the Language Conversion, Select
Text
Module
and
Enter
Text
Module
Name
&
Click
on
create.
Here, we are converting English text to French text, so we have to enter the French conversion of the
English text.
Text 1: TEXT IN ENGLISH.
Click on Save.
Similarly create the text module for text French to English.
Text 2: TEXT IN FRENCH
STEP 5: Once the Text modules are created, Go to Transaction SFP to design form builder for the
interface ZTEXTMODULE_TEMPLATE.
STEP 7:
After clicking on create, the system would prompt you for the Interface name and description.
In Interface Name tab : ZTEXTMODULE_TEMPLATE.
In Description
STEP 8:
Right Click on Form name in the context area and create New Folder.
STEP 9:
Drag
&
Drop
Flag1
field
from
the
import
area.
STEP 10:
Right Click on New FOLDER, create three texts for the text modules.
part
in
to
the
Context
STEP 11:
Double
click
Condition
on
the
new
folder.
The
following
screen
appears.
STEP 12:
Double-Click on Text and maintain the properties as shown below.
Description as Convert TEXT INTO ENGLISH into FRENCH
Text Type
: Text Module
Text Name
Text Language : FR
Click
on
STEP 14:
In our layout, let us also include a logo and some text as well.
Go to Master Page. From Library Palette, insert image field and text into the master page.
Enter text in text field and Enter image in image field and check the checkbox Embedded image data.
STEP 15:
Go to Body Page.
Create following three text fields:
Text in English
Text in French
Text in Italian.
Now right click on the text field and select the option floating fields.
Now we need to do the binding for the text field. Select the text field Text in English, Click on palette click
on object go to binding tab. Please see the following screenshot for the binding.
Now repeat the above step for binding the other two text fields.
STEP 15 - 2:
Second way is Drag & Drop from the Data view.
Just below the text field drag & drop the text field from the data view, in this case you dont have to do the binding,
it will assign automatically.
STEP 16:
Click on Save and Activate it.
STEP 17:
Click on Execute. Assign Value X to Flag1. Otherwise it only display in English. If FLAG1 has value
X than test will display in English & French Both.
Output:
Step2: Go to Object Palette and in Binding TAB update Default Binding with corresponding field by pressing
Arrow and choose form the Interactive From Context.
Step3: Pop-up screen will come to confirm the update of field properties. Click OK. If you do so all properties will
be updated at the same time the UI element will change to normal input Field. You need to change this to Dropdown list in Object Palette->Field Tab as shown below.
Step4: Now you are done with implementing Standard value help for you adobe interactive form. Save and
activate your form and test application. Now you can see Standard value help once you click drop-down link on
adobe form.
This is simple and Zero coding required in application.
Step2: Select corresponding Values and texts into one internal table or populate internal table with possible
values and bind that internal table to context node.
Sample Coding:
* Create internal table
types:
data:
*
t_country
begin
type
of
STANDARD
Select
select
into
land1
end
TABLE
x_country
type
of
OF
from
table
,
t005-land1,
x_country.
x_country.
Data
land1
t005
t_country.
DATA
lo_nd_adobedata
TYPE
REF
TO
if_wd_context_node.
DATA
lo_nd_countrynode
TYPE
REF
TO
if_wd_context_node.
DATA
lo_el_countrynode
TYPE
REF
TO
if_wd_context_element.
DATA
ls_countrynode
TYPE
wd_this->element_countrynode.
*
navigate
from
<CONTEXT>
to
<ADOBEDATA>
via
lead
selection
lo_nd_adobedata =
navigate
from
lo_nd_countrynode =
*
CALL
new_items
Bind
wd_context->get_child_node(
name
=
wd_this->wdctx_adobedata
).
<ADOBEDATA>
to
<COUNTRYNODE>
via
lead
selection
lo_nd_adobedata->get_child_node(
internal
METHOD
name
table
wd_this->wdctx_countrynode
).
to
context
lo_nd_countrynode->bind_table
EXPORTING
= t_country.
Step3:
In Layout editor Choose field Enumerated Drop-down List form Library Palette and place on the layout
Step4: Go to Object Palette and in Field tab click List Item link as fallows.
Step5: One pop-up screen will come and there you need to set Binding properties Items, Item Text and
Item Value as shown below and Press OK.
Items-> Context node
Item Text-> Text field in Context node
Item Value-> Value field in Context node
Now you are done with implementing Static/Context based value help for you adobe interactive form. Save and
activate your form and test application. Now you can see Static/Context based value help once you click dropdown link on adobe form.
Comparison
Coding Required
Online
Offline
Standard
No
Yes
Not available
Static
Yes
Yes
Yes
Note: Maintain Interface type ABAP-Dictionary Based interface. (IN ECC6.0 Version)
Step 2: Create Global Types as shown below by clicking on Types, here we are creating a Nested Table
type which consists of 2 Individual fields (carrid, carrname) and an Internal Table(spfli).
Step 3: Create Global Work Areas and Internal Tables as shown below.
WA_SCARR
IT_SCARR
WA_SPFLI
IT_SPFLI
WA_FLIGHT
IT_FLIGHT
TYPE
TYPE
TYPE
TYPE
TYPE
TYPE
SCARR
SCARR_TAB
SPFLI
SPFLI_TAB
TYPE_FLIGHT
TABLE_TYPE_FLIGHT
WA_SCARR
IT_SCARR
WA_SPFLI
IT_SPFLI
WA_FLIGHT
Output Parameters:
IT_FLIGHT
Step 5: Write the below code in code initialization part. Check for errors and activate the interface.
Step 8: In the Context tab of the Form we will find two sections Interface and Context.
In Interface we will find the data that was created in the interface. We need to drag the elements that need to be
displayed in output into the content area.
Then Right-Click on the Content Area and click on Insert SubForm and Resize it accordingly.
After that Click on Master Pages and then Drag and Drop a Text and Enter any suitable Text.
Then Right-Click on data and create one more Sub Form and align it as shown below.
Step 9: Click on Subform and then in Right-click on the Subform and then in Palettes click on Object and
then under Objects Tab click on Subform and make the Content as Flowed as shown below.
Then Create one more Subform and Rename it as Table and then Right-click on this Form and in Palettes
click on Accessibility make the Subform role as Table and make its Subform content as Flowed as in above
case.
Step 10: Then Insert two Sub Forms in the Table Sub
Form, rename it as Header and Body, make sure to
make them as Flowed too, and make the Accessibility of the two Subforms as Header Row and Body Row
respectively.
Then Insert a Static Text in Header and insert the Field names as shown below.
Step 11: Then under Data View, individually Drag and Drop the Fields from the table it_flight in Body Sub
Form.
Fields are CARRID,
CARRNAME,
SPFLI.
Step 12: Then under Hierarchy tab Select the 3 Fields (i.e. Carrid, Carrname, and SPFLI) and then drag
drop them in Body Sub Form as shown below.
Then make the Body Sub Form as Flowed as well as make its Flow Direction as Western Text as shown
below.
Step 14: Under the Pagination Tab of Body Subform in Overflow choose the Go To Content Areavalue as
ContentArea1.
Step 15: Change the Binding of the Body Subform as shown below.
Change binding for CONNID and fields related to SPFLI as shown below.
Step 17:
Save and Activate the form.
Step 18:
Execute the form. The following output will be displayed.
Chose Create (f5) and provide the necessary description for the same.
Enter the description and provide the interface name as ZTABLES, which is created earlier.
First deactivate all the fields in the table itab and then select the fields to be visible in the output (right
click on the field and choose activate) as shown below. Repeat the same for the internal tables itab1 and
it_final as well .
Now drag the fields from the data view to the design view...and arrange them in a specific order in which
you want and create a text element for the header. Here you can change the font and size for the text
element in the right side pane.
Double-click on the image dragged from the library (here it is shown below) then it will show a F4 help for
selection of the image like this..
Click on the image and choose open then it will be on the body page and you can select the image and
increase the size of the image also
For the image to be displayed on the form, it is important to do this. Right Click on the image and click
on object and check the EMBED IMAGE DATA checkbox.
To put the image as a background, select the image into the body page and right click on the image and
choose send backward then it will become the back ground like this..
(You need to check the checkbox EMBED IMAGE FIELD for the background image here as well)
Save, Activate and execute it .