cancel
Showing results for 
Search instead for 
Did you mean: 

Display data from Function module and from webdynpro

Former Member
0 Kudos

Hi Experts,

I am displaying data in a table using function module. Total 5 columns are there, in this 4 columns i want to fill from function module and one column i want to fill from webdynpro. this is based on user id. these are fixed vaules based on conditions?. from function module i am getting data using service call, how can we fill last column from webdynpro?? any help pleae...

Thanks and Regards,

venkat.

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi,

You have to have 5 context elemtn in under one node having cardinality 0:n, and 4 context element has to be filled with internal table result, remaining one column has to be given by Web Dynpro.

Use loop and you can acheive this as Adithya told.

Regards!

Sheik

Former Member
0 Kudos

I think it is not possible to create one column separately.

Column is a attribute of WD context node that is bound to table. Adding a column means adding a attribute at run time to context node, which will result in exceptions related to illegal reference.

Other way out is create a new context node, and set the data from function module and webdynpro, and bind the same to data source property of your table.

Best regards,

Chiinnu

Former Member
0 Kudos

Hi ,

Since you are using a table , I am assuming that you have a context node of cardinality 0:n.

Declare a itab of your node type and a work area.(say lt_table and ls_table.)

Suppose the data from your FM is in another itab (say lt_itab).

LOOP AT lt_itab INTO ls_itab.

Put all values from the workarea (of data from FM)to the workarea of node.

Fill in the last field of workarea(which you specified as based on logged in user).

Finally append data to table.

APPEND ls_table IN TO lt_table.

CLEAR ls_table.

ENDLOOP.

now bind this table to the context using bind_table() method.

Thanks,

Aditya.