Integer with Layout DIS(zz,zzz,zz9)

Author: neill.king@travelport.com (Neill)

I have a numeric field with an I4 (Integer) interface.

If you enter a number with a decimal point e.g. 123.45 Uniface will truncate the field to exclude the decimal point i.e. result would be 123. Entering a number 123.78 would round i.e. result would be 124.

If a layout is now applied which includes comma separators for thousands and millions when entering 123.45 you end up with 12,345 or 123.78 ends up with 12,378 i.e. the decimal point is stripped and the digits after decimal point included in the overall figure. 

Is this a bug (I am using Uniface 9..3.02.01 P215) or can it be approached in a different way?

Any ideas greatly appreciated.

2 Comments

  1. Hi Neill,

     

       It's  a long time since I looked at it but I think the scaling is the problem.  I4 won't show anything after a decimal point - I4.2 will, but I'm not sure how that stores - you would need to check.

     

      Numeric field with C interface and scaling may be the easy answer.

     

    Dave


    Author: None (None)
  2. I decided this was probably the only way to do it in the short term, but thanks for confirmation.

    Sorry for not responding earlier - I have now updated my email on my profile so it sends to the correct place!

     


    Author: Neill (neill.king@travelport.com)