on 03-09-2006 11:01 AM
Hi All,
I have some problem in getting of input value from View to customcontroller.
My problem is I have created a Input field in the view and if Iam giving the value to that field I can capture the value from View to customcontroller and send it as BAPI input.But My input filed is in the view Context.
How can i capture InputFiled value from View to CustomController.
Advance thanks
Nageswara.
Message was edited by: nageswar mandapati
Nageswar,
Map attribute / nodeattribute in view controller to attribute / nodeattribute in custom controller.
For this add custom controller as required in view controller "Properties" tab, then select attribute / node, right-click and set mapping.
VS
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
What I usually do is; in the custom controller I've created an 'execute' method to be called by the view once the user has input his/her values, you've probably done the same. I pass those input values as parameters to the execute method.
The values can also be passed through the context but I just prefer passing parameters to the method, don't know why really.
I hope this helps,
Patrick.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for your response Patrick,
In my customcontrollerView all my BAPI mathods instances and execute methods are declared.All the attributes directly getting from model class.
But I have two views , in first view I created a input field(for that i created valueAttribute in that context).
Here I want give the conditions If the input field is empty then directly call the execute method of BAPI.
Otherwise give any input to the inputfiled then capture that value and send it input to BAPI from view to BAPI.
In my customcontroller
BAPI b = new BAPI();
b.Param1();
b.param2();
and
execute BAPI()
I done like this.
How can i capture the view input value how to send as a b.parama();
Please guide me .
Any snippests appriciate.
Thanks
nageswara.
Please create a context mapping between the view context attribute and the controller context attribute.
Now whatever value that you have entered would be present in the controller and you can set the BAPI input as follows.
b.setParam1(wdContext.currentContextElement().get<attribute Name>());
Regards,
Noufal
Thanks for response Nouful.
In my Customcontroller All attributes only Model BApi node elenments only.
In my view I created new Value attribute .
How can i Mapp userdefine value attribute to Controller.
Please guide me.
Nageswara
Sorry, this behalf of nageswara mandapati only
Message was edited by: gopi krishna
Message was edited by: gopi krishna
User | Count |
---|---|
86 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.