Symptom
A value set in an XML view or XML fragment is reported as invalid in the browser console. Depending on the property type, this appears in one of two forms:
-
Most commonly, for a number, boolean, or enumeration property, the value is logged and not applied (the application keeps running):
[FUTURE FATAL] Value '...' is not valid for type '...'For example,
myFloat="<not a float value>"on a property of typefloatlogs[FUTURE FATAL] Value '<not a float value>' is not valid for type 'float'. -
For an array property, a real
Erroris additionally thrown, so the affected control no longer renders:Error: "..." is of type object, expected ...[] for property "..." of Element ...For example,
myFloats="[0,100]"on afloat[]property throwsError: "0,100" is of type object, expected float[] for property "myFloats" of Element ....
This happens when a property is set in XML with a value that is not valid for its type, most often by wrapping the value in square brackets (JSON-array style) such as ='[50]', ='[0,100]', ='["..."]' or ="[]". It applies to the number and boolean types int, float, boolean, to enumeration types, and to their respective array types (int[], float[], boolean[], ...).
Read more...
Environment
SAPUI5 / OpenUI5, as of version 1.152 and greater
Keywords
is not valid for type, render, array, rangeslider, [FUTURE FATAL] is of type object, expected invalid property value XML view XML fragment square brackets DataType int[] float[] boolean[] string[] enum nonWorkingDays nonWorkingHours 1.152 XMLTemplateProcessor Control properties , KBA , CA-UI5-COR , Core and Runtime , Problem
About this page
This is a preview of a SAP Knowledge Base Article. Click more to access the full version on SAP for Me (Login required).Search for additional results
Visit SAP Support Portal's SAP Notes and KBA Search.
SAP Knowledge Base Article - Preview