08-06-2009 8:14 AM
Hello,
I have a screen with some input fields in the header (e.g. input field s1) and a tree below them. Using a modal dialog box, I add new values in the tree. My problem is that after I enter a specified value (x1) in the input from modal dialog box and I press 'Save', except adding the new node to the tree, I want to update the value from the header (s1 = s1 + x1). I tried to make update on input field, but the value still remains the old one (s1 from the beginning). Could you please give me some suggestions to solve this situation?
Thanks in advance,
Alexandra
08-06-2009 8:25 AM
Hi
If you are passing a value to a screen field in PBO and change the value in either PBO or PAI it passes the same old value which is in PBO. so
case first_time.
when ' '.
input_value = 'AAAA'.
first_time = 'X'.
endcase.
from second time onwards it will take the updated value only
and make sure your variables are declared in TOP Include
Hope this will serve your purpose.
Regards
Ramc
08-06-2009 8:50 AM
I'm sorry, but could you specify where I should insert this (in PAI or PBO)?
08-06-2009 8:55 AM
08-06-2009 9:06 AM
08-06-2009 2:00 PM
Finally I found a solution that works fine for me. I use
CALL METHOD cl_gui_cfw=>set_new_ok_code
EXPORTING
new_code = 'SAVE'.
and for ok_code with value 'Save' I recalculate values from header and then the refresh is done.
Hope this will help somebody in the future.
Thank you all for your answers!