‎2008 Jun 20 10:53 AM
Hi,
I am using a maintenance view to insert values into a table. When user creates a new entry, based on the value provided for a field,I need to fill a read-only field. In PAI, when user enters a value for one field, I am using FM 'DYNP_GET_STEPL' to get the current line and then DYNP_VALUES_UPDATE to fill the contents to the read-only field. But this does not seem to work. Any idea?
Regards
Rachana
‎2008 Jun 20 10:58 AM
Hi!
You can't enter values into a read-only field, using DYNP_VALUES_UPDATE fm.
However you have 2 choices:
- you have to enter the value into the structure behind the dynpro field
- you have to remove the read-only attribute from the field (using LOOP AT SCREEN statement), then set the value and set the read-only status back.
Regards
Tamá
‎2008 Jun 20 12:28 PM
Hi Tamas,
I tried both the options suggested by you.
I am updating the underlying structure, still its not visible when the screen loads again. But if you see the same field gets filled with DYNP_VALUES_UPDATE if an F4 help is used for teh first(editable) field and then my read-only field is also filled in the PROCESS ON VALUE REQUEST module.
So my guess is that, since it is a table control, it loops through the rest of the table control which is empty and my underlying structure gets cleared. So the problem could be where I am actually filling the field.
Is it possible to somehow fill the <EXTRACT> table so that teh value is not lost?
Regards
Rachana
‎2008 Jun 20 12:37 PM
Hi Rachana,
After updating the structure, update the internal table values for the current row. I think you are not updating internal table.
Regards,
Siva.
‎2008 Jun 20 12:35 PM
Hi Rachana ,
You dont need to use the FM , you will have to implement the event NEW_ENTRY in the table maintenance ,please check the help on events in table maintenace .
In the subroutine you create , you will have the values enetred by the user in the work area of the table which has the same name as the table .
Do revert back in case of further queries.
Regards
Arun