on 2005 Aug 01 11:34 PM
Hi all,
I'm running a webdynpro application that calls a RFC with data from a view and then execute that function from the component controller...the problem is that I don't know how to do that.
Thanks in advance,
Jesus.
hi
first you have to map the context nodes and attributes in the view to those in component controller . now add the controller to the view. do all necessary initialisation of the model node in the implementation part on controller. now create a method in the controller . inside the method write the code to execute the rfc. now call method from any action in the view.(this method won't be accessible from view if the componentcontroller is not added to the view).
regards
rahul.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Right click on the Component controller you will get option to apply template .
select the service controller template . It will create a method in the controller if you select the correct attributes of the model node.
Just call the method from the view as Pran has said.
Hope that would solve your problem.
Get back if you have further queries.
Regards
Noufal
Check this tutorial:
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/webas/web dynpro tutorial and sample applications.faq#q-4
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Adding to Anil's comment,you should also create SLD for your R/3 client system which you wish to connect through JCO using webdynpro.Then create a Model out of it and supply it with the input & output parameters required and bind it with your component controller.
Regards,
Guru
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
1. Goto the view properties and the "cpmponentController" in the required controllers.
2. and write the following code in the view.
wdThis.wdget<<ComponentController>>.execute<<MetodName>>
3. Makesure that you created a mapping btn the componentController ModelNodes and viewModelNodes
Regards, Anilkumar
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi
You will have to bind the component controller with the view controller. This would make the component controller object accessible to the View controller and there by its methods
wdThis.wdGet<component controller>.<method>
Regards
Pran
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Jesus
Hope I get it right this time
->Create nodes in your component controller that model the data
->map the nodes to the view you want to fetch the data from.
->populate this node from your view based on whatever action. This data then becomes available in your component controller
Regards
Pran
Hi pran, you almost get it.
Please can you tell me the instrucction that >I have to do with my nodes?...I have already donde something..have don the bind to the bapi and of course the execute method that I use to call the bapi from the view.
I'm wondering if you have hotmail or MSN..mine is castillo_jesus@hotmail.com..if you don't mind you can add me to your contacts so we can chat about my problem.
Thanks a lot.
Jesus
Hi jesus,
Bind ur view context nodes with ur controller context node so that again u need not pass the values from view to the controller. Now u have all the values in the controller itself. Now in the controller method set all these values to the model node.
sample code to set the values from current context to the model node (where agenda is my attribute and ztrng_Insert_Inputone is my model node that is bound):-
wdContext.nodeZtrng_Insert_Inputone().currentZtrng_Insert_InputoneElement().setAgenda(wdContext.currentContextElement().getAgenda());
(previously u should have model node and context node also mapped). Thus once u set all the nodes, u can execute ur bapi now.
Regards,
R.S.Sirisha.
Hi,
Please refer my article on Linking RFC to Web Dynpro.It will help you to solve your query.
https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/webas/webdynpro/li... rfc to web dynpro.pdf
Regards,
Vijith
User | Count |
---|---|
71 | |
11 | |
11 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.