Skip to Content
Jan 27, 2021 at 04:19 PM

Index showing as NaN on Title in UI5 Application

40 Views Last edit Jan 27, 2021 at 04:20 PM 2 rev


I am using an Index to set the number on a title which is inside a panel. The Index is getting displayed as NaN on the UI. I am attaching the UI5 code for your reference.

<l:VerticalLayout visible="{=${PATH} === 'R'}" width="100%"> 
<l:Grid containerQuery="true" content="{/INFO}"> 
<Panel backgroundDesign="Transparent"> 
<Title text="{i18n>label.billto} #{=${Index} + 1}"/> "  This gets set a NaN on the UI
<Title visible="{=${BPName}!==''}" text="{BPName}"/> 
<Text visible="{=${BPAddress}!==''}" 
text="{ parts: [ {path:'Index'}, {path: 'BPAddress'}, {path: 'BPCity'}]}"/> 
<VBox> <HBox visible="{=${documentType}==='AB'}"> 
<Text text="{ parts: [ {path:'Index'}, 
{path: 'i18n>label.from'}, {path: 'i18n>'}, {path: 'i18n>label.willpay'} ]/> 
<HBox> <Label text="{i18n>label.paymentMethod}: "/> 
<Text text="{path: 'paymentMethod'/> 

Here is the screen shot of the output.