Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Problem with User Defined Second Selection Screen

Former Member
0 Likes
608

Hi Gurus,

I have a problem with the selection screen selections. My requirement is that , User when he selects a check box on the main selection screen ( which is 1000) then at the at-selection event, another screen (whose number is 2000) will be called and it has some parameters to enter values. My problem is that how to get the values from this second screen and use them in the in my program. There is an execute button on the second selection screen and when i click that, nothing is happening.

Can anybody suggest me how to get the values from this screen which we called, and entered values in that screen. How to use these values and is there any way that we can do this.

Thanks in advance for helping me out.

Regards,

Srinivas.

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
570

Hi,

What I do with similar problems is when the second dynpro parameters are filled, I return to first dynpro (with a "leave to screen 1000" when you push the button (the button command is stored in the okcode variable that you have defined in the second dynpro)). As I have defined the parameters as global variables, I have the required information in the first one.

Ex

Module USER_COMMAND_2000.

CASE ok.

When 'PUSH'. "Whatever you define

perform receive_parameters.

leave to screen '1000'.

endcase.

Regards

Jaime

4 REPLIES 4
Read only

Former Member
0 Likes
571

Hi,

What I do with similar problems is when the second dynpro parameters are filled, I return to first dynpro (with a "leave to screen 1000" when you push the button (the button command is stored in the okcode variable that you have defined in the second dynpro)). As I have defined the parameters as global variables, I have the required information in the first one.

Ex

Module USER_COMMAND_2000.

CASE ok.

When 'PUSH'. "Whatever you define

perform receive_parameters.

leave to screen '1000'.

endcase.

Regards

Jaime

Read only

Former Member
0 Likes
570

Use <b>DYNP_VALUES_READ</b> FM to read the values from your dynpro screen...

Like this...


DATA: ls_dyname	TYPE d020s-prog,
        ls_dynumb	TYPE d020s-dnum.

gt_dynpfields TYPE STANDARD TABLE OF dynpread WITH HEADER LINE.

    ls_dynumb = '0112'.
    gt_dynpfields-fieldname = 'RF05A-NEWKO'.
    APPEND gt_dynpfields.

  CALL FUNCTION 'DYNP_VALUES_READ'
    EXPORTING
      dyname               = ls_dyname
      dynumb               = ls_dynumb
    TABLES
      dynpfields           = gt_dynpfields
    EXCEPTIONS
      invalid_abapworkarea = 1
      invalid_dynprofield  = 2
      invalid_dynproname   = 3
      invalid_dynpronummer = 4
      invalid_request      = 5
      no_fielddescription  = 6
      invalid_parameter    = 7
      undefind_error       = 8
      double_conversion    = 9
      stepl_not_found      = 10
      OTHERS               = 11.

Greetings,

Blag.

Read only

0 Likes
570

Hi Alvaro,

The second screen has lets say 4 parameters to enter the values and after entering the values , there is an execute button down at the bottom and user , may supposed to be pressing that one. after he presses that one how to get these values to the main screen or use them in the program?

Where can we use this FM , I mean at which event we use this? I mean is it at selection-screen output or initialization. Thanks for your response.

Thanks And Regards,

Srinivas.

Read only

Former Member
0 Likes
570

The issue is solved. Users does not want to go with this custom sub screen option. So, its ok for now.