Skip to Content
author's profile photo Former Member
Former Member

pfstatus help

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

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

2 Answers

  • Posted on Jul 13, 2007 at 01: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

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jul 13, 2007 at 01: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

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.