07-16-2018 9:08 AM
I am facing same issue. unable to read drop down selected value.. please tell me way to read the value
07-16-2018 9:47 AM
What do you mean by 'read drop down selected value' did you write a FIELD statement in the PAI of the subscreen, did you define the field in a structure in main program (some TABLES statement)
07-16-2018 5:14 PM
Sort of hack and non conventionally recommened way is to read screen elements via Field Symbols
Eg :
FIELD-SYMBOLS: <fs_fund_code_value> TYPE tt_aitem_fields,
ASSIGN ('(SAPLAMVT_TAX_CLASS_CODE)MT_EXTDATA_ITEM') TO <fs_fund_code_value>.
Here - tt_aitem_fields is a table type, SAPLAMVT_TAX_CLASS_CODE is name of program and MT_EXTDATA_ITEM is screen element
07-16-2018 5:42 PM
I'd rather say that you assign a global program field and not a dynpro field.
07-17-2018 4:42 AM
Yes I agree. My solution was proposed for such fields which are not part of global or local pool as seen in the debugger.
07-17-2018 5:15 AM
What do you mean? What are"fields which are not part of global or local pool as seen in the debugger." ?
See:
07-18-2018 2:50 AM
My suggestion was about dynpro fields. (As a last resort) Some times at the exit or place where we need to write code, some screen field values are not present but we still need to process them so we can program via screen elements. Also, the variables used to hold dynpro fields are local to the method or subroutine. But yes, I agree that we should minimize or as far as possible do away with global declarations.
For example - in classic SE38 report , we now declare selection screen parameters with reference to variables decalred in an interface.
07-18-2018 6:27 AM
Please don't confuse. As far as I know, you cannot address dynpro fields in ABAP programs. Instead dynpro fields are passed to and from global program variables that have the same name at PAI and PBO.
07-18-2018 11:29 AM
Got your point....I was confused between dynpro fields (which are actually global ) thought that they are local to a program. Also, why are you suggesting to that global program fields are better than dynpro fields. Please shed some light.
07-18-2018 4:22 PM
Please make yourself acquainted with the basics of dynpro programming.
07-18-2018 6:22 PM
07-16-2018 5:39 PM