cancel
Showing results for 
Search instead for 
Did you mean: 

Passing values from one component to another (FPM )

Former Member
0 Kudos

Hi All,

I am not able to pass value from one component to another using Webdynpro ABAP which is using FPM framework.

I have a component(COMP A) which is the first component to be displayed from the FPM. And, when next button is clicked the second component(COMP B) is fired by the FPM. My requirement is such that the data user is entering in the view of COMP A should be passed to the COMP B. Could any please help me about how do I achive this.

Note: I am using FPM framework for navigating between the components.

Thanks

Deepak

Accepted Solutions (1)

Accepted Solutions (1)

arjun_thakur
Active Contributor
0 Kudos

hi,

in comp A , bind your UI element to a context node's attribute and the make that node an interface node. now you can see that interface in comp B. you can use anywhere in comp B

i hope it helps.

regards

arjun

Former Member
0 Kudos

Hi Arjun,

Thanks for your quick response.

I am not getting it clearly what you are saying. Could you please elaborate it further.

Thanks

Deepak

arjun_thakur
Active Contributor
0 Kudos

hi,

when you create a node in a component there is a check box to make it an interface node. If you check that check box, then when you use that component in some other component, then that interface node will be visible in the second component. so now you can bind that node's attribute in your 1st component and can use it in your second component.

i hope it helps.

regards

arjun

Former Member
0 Kudos

Hi Arjun,

I have actually done the same way as you had mentioned.

i.e.,

1. I have created a interface node in the first component (COMP A) and I have done the binding of this attribute to the UI element.

2. I have used COMP A in the second component (COMP B). Now, as you said , the interface node is visible here and I have mapped this to the component controller of the COMP B. But, I am not getting the value that I entered for this attribute in the COMP A .

EX: I have a interface node (FIRST_NAME) in COMP A. When the application is run through the FPM, I entered 'Deepak' in this field. Then I navigate to the the second component(COMP B) through FPM by pressing the next button. Here in COMP B , I am not able to read the value 'Deepak' that I had entered in COMP A.

Could you please help .

Thanks,

Deepak

Edited by: Deepak Kutnikar on Nov 18, 2008 5:43 AM

Former Member
0 Kudos

Hello Deepak ,

I think you are doing this other way round . In COMP B you should have an interface node . And in comp A you should have a usage of COMP B .

Now if you fill this interface node in COMP A and move to B it will be automatically filled .

You can achieve this functionality by interface methods at component controller level. Then you need not to have an interface node .

From COMP A before moving to COMP B , you can call interface method of COMP B to fill the relevant node in comp B . before calling the interface method you have instantiate the COMP B component .

I hope this will solve you problem .

Regards

Vivek

Former Member
0 Kudos

Hi Vivek,

Thanks for the information.

I tried the way you had mentioned. But, unfortunately it also did not work for me. I think the values are getting refreshed when navigated to the second component. And, actually I am using FPM framework for navigation.

Thanks,

Deepak

Former Member
0 Kudos

Hello ERP Consultant,

You have COMP A in which you enter the data which you want to see in the second component COMP B.

To achieve this in FPM frame work, 1st make the nodes as the interface node in the components. And then, you need to implement the FPM interface "IF_FPM_SHARED_DATA". Once you do this, the changes you do in COMP A will be reflected in COMP B.

This will solve your problem.

Thanks and Regards

Rohan

Answers (1)

Answers (1)

Former Member
0 Kudos

hi ,

I am facing same issue ..rather Exactly same issue .So far I have not got solution .

Still in your case you may try sharing data Using Assistance class .

Please check this how to do it

http://help.sap.com/saphelp_nw04s/helpdata/en/43/1f6442a3d9e72ce10000000a1550b0/frameset.htm

http://help.sap.com/saphelp_nw04s/helpdata/en/ec/fd904d9e9d4c7fb2f507c451af0871/frameset.htm

In My case I can not use Assistance class as well , both web dynpro comp. of mine have different web dynpro classes .

Former Member
0 Kudos

Hi,

In my opinion through assitance class it is easily possible, even if classes are different you can make your attribute as public in one class and make a method in second class to access the public variable of first class and then call this method in your component.

Hope this works.

Regards

Manas Dua