Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Error in Module pool/Screen while passing value as Decimal value

Former Member
0 Kudos

Hi Experts,

We have designed one customized screen with CHAR as input option to pass on Tax Percentage. We have defined as CHAR in screen logic as well as program also.

Where as while we enter value with decimals like 2.5 or 5.4 its throwing a error message "Entry is too long for the field". But when I pass on Integer values like 2 or 4 then its working fine.

Can you pls suggest on this how to rectify this error.

Thanks in advance.

VJ

4 REPLIES 4

Former Member
0 Kudos

Hi,

Declare the field type as below and check in the debug mode where exactly its falling.

DATA P_FIELD TYPE P DECIMALS 2.

Regards,

Kumar

Former Member
0 Kudos

Hi,

Increase the length of the character field in the screen as well as in the program declaration.

Example;

DATA gv_tax(10) type C.

Regards

Karthik D

0 Kudos

Hi,

Thanks.

I have tried by defining Variable as P with Decimals 2 as well as by increasing the field lengh to 25 in screen field. Still the same problem exists. Could you pls provide other alternatives.

Thxs&rgds,

VJ

Former Member
0 Kudos

Hi,

Declare as follows

data: p(4) type p decimals 1. in the program

goto the screen layout->click on button 'program/dictionary fields' and enter '*' and click on 'get from the program', there you can find 'p' which we declared. select if and click 'ok' button