2015 Apr 21 1:06 PM
Hi Friends,
i have designed screen as shown in standard infotype with section(F4), Discipline(Drop Down), Sub Function(F4) as shown in picture
-->now when i select a value from selection using f4 Description(Assitant Manager) is being displayed using DYNP_VALUES_UPDATE(FM) as seen in picture below
--> same way i have selected for sub fuction using f4 , description(Test1) is available as shown in picture below:
--> all this code i have done in POV using above said function module.
now the issue is after saving when i click on display or change the description are not displayed as per the respective ID's as shown below picture.
so i have again used the fm in PBO as below code:
data: wa1_ZHR_SECTION TYPE ZHR_SECTION.
data: it1_dynpfields type TABLE OF DYNPREAD,
wa1_dynpfields LIKE LINE OF it_dynpfields.
if P0001-ZZSECT IS NOT INITIAL.
select SINGLE * FROM ZHR_SECTION into CORRESPONDING FIELDS OF wa1_ZHR_SECTION WHERE ZSECTION = P0001-zzsect.
ENDIF.
* BREAK-POINT.
clear wa1_dynpfields.
wa1_dynpfields-fieldname = 'T1'.
wa1_dynpfields-fieldvalue = wa1_ZHR_SECTION-description.
APPEND wa1_dynpfields to it1_dynpfields.
* BREAK-POINT.
call function 'DYNP_VALUES_UPDATE'
exporting
dyname = sy-repid
dynumb = sy-dynnr
tables
dynpfields = it1_dynpfields
* EXCEPTIONS
* INVALID_ABAPWORKAREA = 1
* INVALID_DYNPROFIELD = 2
* INVALID_DYNPRONAME = 3
* INVALID_DYNPRONUMMER = 4
* INVALID_REQUEST = 5
* NO_FIELDDESCRIPTION = 6
* UNDEFIND_ERROR = 7
* OTHERS = 8
.
but the descriptions are not being displayed. did i miss anything.
2015 Apr 21 6:29 PM
hi siva,
IN PBO instead of calling fm 'DYNP_VALUES_UPDATE'
assign direct values to field T1 such as
T1 = wa1_ZHR_SECTION-description
hope it helps.............
2015 Apr 21 1:44 PM
In the PBO event, write a module and in the module fill the value of the description field based on Sub section value. It should work. Ensure you are passing the value to the correct field on the screen painter for the description
2015 Apr 21 4:40 PM
Hi Atul, The code i have provided above, is provided in POV, so when we click F4 and select value, then its corresponding description is being displayed. Now i have copied the same code to PBO as you can see above, but it is not displaying. I have a doubt, in which PBO we have to provide, i was providing in PBO of 200 screen, but i can see one more PBO in includes(ZP058120). i am confused which is exactly the PBO here for my Custom fields in standard infotype. right now i am creating all the modules in PBO,PAI,POV of 200 screen and on double clicking for code implementation i am selecting main program, instead of ZP058110,ZP058120,ZP058130,ZP058140. am i going in right direction????
2015 Apr 21 6:11 PM
Hi
You have provided a screen in your post above. Now click the cursor on the field 'sub function' and press F1 then from the screen that I appear click on technical details. It will show you the screen no and program name. Click on the screen name and it will take you to SE51.
Now on this screen u need write the PBO Module.
In that module fill the value for description field based on sub function' value.
2015 Apr 21 6:29 PM
hi siva,
IN PBO instead of calling fm 'DYNP_VALUES_UPDATE'
assign direct values to field T1 such as
T1 = wa1_ZHR_SECTION-description
hope it helps.............
2015 Apr 22 5:17 AM
Hello Siva.
When data is available in a screen field, it will be reflected in screen via PBO.
Please check if the description gets cleared inside any module of PAI.
Otherwise it should be fine .
Regards.