cancel
Showing results for 
Search instead for 
Did you mean: 

Variable Pop-up input Screen

benahmet
Explorer
0 Kudos

Dear Consultants,

I want user to enter the target value manually in the pop-up screen.For Example : In the Copy Function instead of entering the target version value into the function,I want user to enter the target value value manually in the screen during function execution.

Is there any way to do it?

or do I have to enter it into the function all the time?

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi,

you can create a planning folder and include the function in that. Also create 2 variables target and source, use these variables in the function.

PS- Create a copy function and select the verion as the field to be changed. IN the parameter group select the variable from in the from field and the variable to in to the to field for version.

hope this was helpful..

thanks

Former Member
0 Kudos

Hi,

you can create a planning folder and include the function in that. Also create 2 variables target and source, use these variables in the function.

PS- Create a copy function and select the verion as the field to be changed. IN the parameter group select the variable from in the from field and the variable to in to the to field for version.

hope this was helpful..

thanks

Former Member
0 Kudos

Hi,

What you can do is create an exit variable and use it in your planning level. In the exit variable you can use the function module "POPUP_GET_VALUES" or another one from function group SP04 or SP03 to request the value from the user.

Mike.

former_member192142
Contributor
0 Kudos

Hi Michael,

This could be very usefull for me. Do you have an example of the code used to define the exit variable?

Thanks in advance,

-Jacob

Former Member
0 Kudos

Jacob,

This How-To Document should give you some ideas.

https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/documents/a1-8-4/how to variables of type exit.pdf

hope it helps.

Hari Immadi

http://immadi.com

SEM BW Analyst

former_member192142
Contributor
0 Kudos

Hi Hari,

Thanks for your response, but I'm familiar with the How-to paper. I actually meant more information on the POPUP_GET_VALUES function module, but I wasnt 100% clear.

Thanks,

-Jacob

Former Member
0 Kudos

Here is the sample code on how to use POPup_GET_VALUES.

DATA: i_sval Like sval occurs 0 with HEader Line.

data: v_subrc like sy-subrc.

i_sval-tabname = 'LIKP'.

i_sval-fieldname = 'WADAT_IST'.

i_sval-fieldtext = 'Shipping Date'.

i_sval-field_obl = 'X'.

append i_sval. clear i_sval.

i_sval-tabname = 'KNA1'.

i_sval-fieldname = 'NAME1'.

i_sval-fieldtext = 'Carrier'.

i_sval-field_obl = 'X'.

append i_sval. clear i_sval.

i_sval-tabname = 'MAKT'.

i_sval-fieldname = 'MAKTX'.

i_sval-fieldtext = 'Tracking#'.

i_sval-field_obl = 'X'.

append i_sval. clear i_sval.

v_pop_title = 'Enter Shipping Details'.

endif.

CALL FUNCTION 'POPUP_GET_VALUES'

EXPORTING

  • NO_VALUE_CHECK = ' '

POPUP_TITLE = ‘Title for popup

  • START_COLUMN = '5'

  • START_ROW = '5'

  • IMPORTING

RETURNCODE = v_subrc

TABLES

FIELDS = i_sval

EXCEPTIONS

ERROR_IN_FIELDS = 1

OTHERS = 2

.

IF SY-SUBRC <> 0.

MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO

WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.

ENDIF.

former_member192142
Contributor
0 Kudos

Hi,

Thank you for the sample code? I've implemented it and it seems to work. Now I have a very basic question:

Where do I find the values that I entered in the pop-up? In i_sval? The Value field in that table is empty when I debug it.

Thanks in advance,

-Jacob