cancel
Showing results for 
Search instead for 
Did you mean: 

Adobe field binding

Former Member
0 Kudos


How to bind two fields in a column?

I want to display my ouput in table format, while doing that i am not able to concatenate/ bind two table fields in a column.

eg. i have two fields (username and name_text)

     both the fields were two different columns in my layout.

     but now i want both the fields in single column?

Regards

Nishant

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi Nishant,

If you want those two fields values in one field you can try this below code.

Click on the username column. In the Initialize event, write the below Java script code:

var username = this.rawvalue;

var name_text = name_text.rawvalue;

if(this.rawvalue != null && name_text.rawvalue != null)

{

this.rawvalue = username + name_text;

}

varun_vadnala3
Active Participant
0 Kudos

Hello Nishant,

Use floating fields in the column where you want to display both iser name and name_text.

Now bind these values to the respective folating fields.If the values are present then it will display or else you will have empty space.

For floating fields use text from standard library.

regards,

Varun

pavan_prabhu
Active Participant
0 Kudos

Hello Nishant,

1) Remove one column from layout.

2) Then in Form Interface, using ABAP you can concatenate username and name_text in only one column in that table. Change that table structure.

3) Then in the Context node,refresh that structure. Then drag the table again from data view in Body page display that table in the layout.

Former Member
0 Kudos

Hi Pawan,

Is it not possible without changing the table structure?

pavan_prabhu
Active Participant
0 Kudos

Hi Nishant,

     If you want to achieve this without changing the structure, then follow the steps below.

1) Hide the column name_text in the layout.

2) Increase the length of username column in your structure considering the additional length of name_text. You don't need to change the whole structure as such.

3) Click on the username column. In the Initialize event, write the below Javascript code.

this.rawvalue = this.rawvalue + this.parent.name_text.rawvalue;