09-17-2008 9:26 AM
Hi there, I need a small tip.
The problem is with the quantity.
My itab has field
mymenge TYPE i .
But there is a small problem.
When I put that value into TABLEVIEW object and column is shaded (gray background) the '0' value is visible (field format in screenpainter is set to INT1 to avoid entering characters, only digits are possible)
but ... when I set that column editable (white background) the '0' value is not visible.
And I need to see those zeros. User must see when value is '0' and when it's just empty.
Can You give me some tip how to solve that problem? I'd be thankful for help. Greetings
09-17-2008 9:55 AM
i had got the same problem
u need to define separate screen field as a character
and after calculating assign your numeric field to screen field,
at the time of validation
you can check value is between '0000' to '9999'
for user to prevent from entering character value
Regards
Alpesh
09-17-2008 9:43 AM
Not sure how to do this with type I, but maybe type N is an option, allows only digits as well, but is a character field by definition.
mymenge TYPE n LENGTH 8
You could also define a separate structure for screen display this way and transfer to another structure with the original type I definition at PBO/PAI.
Thomas
09-17-2008 9:58 AM
09-17-2008 10:12 AM
I see. Type C would distinguish between space and 0, but then you have additional effort to ensure only valid quantities are being entered. Might be an option, unless somebody else comes up with a better idea.
Thomas
09-17-2008 9:55 AM
i had got the same problem
u need to define separate screen field as a character
and after calculating assign your numeric field to screen field,
at the time of validation
you can check value is between '0000' to '9999'
for user to prevent from entering character value
Regards
Alpesh
09-17-2008 10:37 AM
Alpesh
at the time of validation
you can check value is between '0000' to '9999'
My CHAR type is of 3 characters. How to check thing You're writing of?
When I move INT value '0' to CHAR value '0'
the comparison :
IF ( charvalue >= '000' ) AND
( charvalue <= '999' ) .
* debugger is not entering that place of code
ENDIF .
09-17-2008 10:50 AM
For validation, why not:
IF NOT charvalue CO '0123456789 '.
* Error message
ENDIF.
Regards,
Valter Oliveira.
09-18-2008 6:05 AM
CONDENSE charvalue NO-GAPS.
IF NOT charvalue IS INITIAL.
IF NOT charvalue BETWEEN '0' AND '999'.
CLEAR charvalue.
MESSAGE E398(00) WITH 'Please enter numeric Value'.
ENDIF.
ENDIF.
use this code.
Edited by: Alpesh on Sep 18, 2008 7:06 AM
Edited by: Alpesh on Sep 18, 2008 7:08 AM
09-17-2008 9:59 AM
Hi,
Try to define it as QUAN field on Screen but there should also be a UNIT field as the Reference field for it.
09-17-2008 10:19 AM
Neha Shukla
Field format - QUAN
Reference field - UNIT
'0' still not visible