2009 Jan 23 5:47 AM
Hi,
I have one column in ALV output which is editable .I have defined that in this way:
data :input type resb-bdmng.
fieldcatalog-fieldname = 'INPUT'.
fieldcatalog-seltext_m = ' Scrap'.
fieldcatalog-col_pos = fieldcatalog-col_pos + 1.
fieldcatalog-input = 'X'.
fieldcatalog-edit ='X'.
APPEND fieldcatalog TO fieldcatalog.
CLEAR fieldcatalog.
But if we edit the field in the output it gives error : " Too many decimal places ( maximum 0)"
If we add fieldcatalog-datatype = 'DECIMAL'. then it works fine but in that case it throws dump for toolbar button " Export to the local file " Its functinality is copied from standard interface SAPLKKBL program The dump is The current statement requires chaarater data type object .It cant take decimal fieldcatalogtype . If we remove fieldcatalog-datatype = 'DECIMAL'. then this button works fine but in this case the first error comes "Too many decimal places ( maximum 0)"
Please suggest how can I remove first error without setting fieldcatalog-datatype = 'DECIMAL'. property.
Will definetly ..... if its helpful
2009 Jan 23 6:03 AM
Try passing reference table and field in your fieldcat.
fieldcatalog-ref_fieldname = 'BDMNG'.
fieldcatalog-ref_tabname = 'RESB'.
Regards
Sathar
2009 Jan 23 6:03 AM
Try passing reference table and field in your fieldcat.
fieldcatalog-ref_fieldname = 'BDMNG'.
fieldcatalog-ref_tabname = 'RESB'.
Regards
Sathar
2009 Jan 23 6:19 AM
It works . But in this case the column name is coming as the refernce field name which I dont want .
I want it fieldcatalog-seltext_m = ' Scrap'.
Please suggest
2009 Jan 23 6:59 AM
hi
It might be bcoz of length probelm of output field scrap .
us fieldcatalog-outputlen = '30' like that
2009 Jan 23 7:06 AM
hi,
This is a common problrm when yu want to display the values in decimals...if the datatype is any other than character, if u try to export to file,it will throw dump.change the datatype into character in ur internal table itself ,,then calculte the values in decimals and insert to this fieldand display.Now it will allow edit and wont throw dump
Edited by: soniya baboo on Jan 23, 2009 8:07 AM
2009 Jan 29 7:28 AM
Hi
Thanks for your reply. I have found the solution that is
fieldcatalog-datatype = 'PREC'.
Its solves my all the problems.
Thanks
| User | Count |
|---|---|
| 4 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |