Transfer a parameter from one view to another
Probably this question was asked many many times before, but then i probably use the wrong search criteria, because i can't find them.
My question is simple: I am on a header view and depending on an action which i perform there, i want to fill a certain variable. I need the value of this variable in the next screen, which is on item level.
What possibilities do I have to transfer this value? (I already tried with server->request->set_form_field and server->request->get_form_field/data, but this didn't work)
Rohit Khetarpal replied
We refer to static class attributes/methods by using operator =>
Say, class1 has attribute 'name1'.
You want to assign this to attribute 'name2' of class2 (or anywhere else) by writing:
name2 = class1=>name1.
Difference in static and instance variables in that for static variables you need not create object of that class every time to access that class. Same value exists in the session, whereas for instance variables there is a different value for each instance.
We create instance of a class by writing: Create Object lr_object type ref to <classname>.
This is not required for static attributes.
I hope it resolves your query.