Bug #10074
FILL-IN: initially unknown value is not changed when format attribute is set
Status:
New
Priority:
Normal
Assignee:
-
Target version:
-
Start date:
Due date:
% Done:
0%
billable:
No
vendor_id:
GCD
case_num:
version_reported:
15938
version_resolved:
History
#1 Updated by Vladimir Tsichevski about 1 year ago
Let’s take a look at this 4GL procedure example:
SESSION:SET-NUMERIC-FORMAT(",",".");
DEFINE VARIABLE finn AS DECIMAL NO-UNDO.
DEFINE BUTTON bSetFormat LABEL "Set Format".
DEFINE FRAME f finn NO-LABEL SKIP bSetFormat NO-LABEL WITH SIZE 30 BY 4.
finn:FORMAT IN FRAME f = "->>,>>9.99".
ENABLE ALL WITH FRAME f.
finn:FORMAT IN FRAME f = "->>,>>9.99".
ON CHOOSE OF bSetFormat DO:
MESSAGE finn:FORMAT IN FRAME f.
finn:FORMAT IN FRAME f = "->>,>>9.99".
MESSAGE finn:FORMAT IN FRAME f.
END.
WAIT-FOR CLOSE OF FRAME f.
This program sets up a frame with a FILL-IN widget and a button. The FILL-IN value isn’t set explicitly, so it starts as unknown, and the displayed value appears empty. The FILL-IN format is set in three different ways: before enabling the frame, after enabling it, and when the user clicks the button.
In OE, setting the format in any of these three ways changes the FILL-IN value to 0.00. In FWD, setting the format doesn’t change the displayed value.
This behavior isn’t limited to decimal FILL-IN widgets - in OE, setting the format for any FILL-IN type with a valid value updates its displayed value.