2007 Jul 13 2:04 PM
Hello Frnd
I had set pf-status for a screen excluding a standard toolbar 'SA'.
i had made a application toolbar 'A' in which i want that if i click on that
pf-status should be active including
'SA'
module STATUS_0001 output.
SET PF-STATUS 'EMPMASTER' excluding 'SA'.
endmodule. " STATUS_0001 OUTPUT
module USER_COMMAND_0001 input.
CASE SY-UCOMM.
WHEN 'A'.
perform yn_popup using 'AD' 'Do You Want To Add ?'.
if user_answer = '1'.
MESSAGE I000.
perform max_emp_no.
endif.
SET PF-STATUS 'EMPMASTER' .
endcase.
endmodule. " USER_COMMAND_0001 INPUT
put for the above code after clicking on 'A'. 'SA' toolbar is still disabled
Please tell me the solution friend
With Best Regards
Ruby
2007 Jul 13 2:14 PM
Hi,
SET PF-STATUS will not have effect in a PAI module you have to put it in PBO module as follows.
<b>DATA: flag. *Put this in the top include.</b>
module STATUS_0001 output.
<b>if flag is initial.
SET PF-STATUS 'EMPMASTER' excluding 'SA'.
else.
SET PF-STATUS 'EMPMASTER'
endif.</b>
endmodule. " STATUS_0001 OUTPUT
module USER_COMMAND_0001 input.
CASE SY-UCOMM.
WHEN 'A'.
perform yn_popup using 'AD' 'Do You Want To Add ?'.
if user_answer = '1'.
MESSAGE I000.
perform max_emp_no.
endif.
<b>flag = 'X'.</b>
endcase.
endmodule. " USER_COMMAND_0001 INPUT
Regards,
Sesh
2007 Jul 13 2:15 PM
Hi
U need to manage it in the PBO, not in PAI, the system after excuting PAI, backs to PBO so it deactives SA again.
module STATUS_0001 output.
if fl_SA = SPACE.
SET PF-STATUS 'EMPMASTER' excluding 'SA'.
else.
SET PF-STATUS 'EMPMASTER'.
endif.
endmodule. " STATUS_0001 OUTPUT
module USER_COMMAND_0001 input.
CASE SY-UCOMM.
WHEN 'A'.
perform yn_popup using 'AD' 'Do You Want To Add ?'.
if user_answer = '1'.
MESSAGE I000.
perform max_emp_no.
endif.
FL_SA = 'X'.
endcase.
endmodule. " USER_COMMAND_0001 INPUT
Max
2007 Jul 13 2:28 PM