cancel
Showing results for 
Search instead for 
Did you mean: 

RAP validation message targeting a composition association does not highlight MultiValueField

11-03-2026 6:56 PM
29 views 2 comments
0 Likes
Subscribe

We are using SAPUI5 1.120 with a Fiori Elements OData V4 application based on RAP but also tested below question with UI versions up to 1.151.

Our application contains a parent entity _Items with a composition association _PackItems. A @UI.lineItem annotation referencing _PackItems.PackType automatically generates a sap.ui.mdc.MultiValueField in the table.

We perform RAP validations and return messages targeting individual fields. All normal scalar properties are correctly highlighted in red by Fiori Elements.

However, when validating that _PackItems must contain at least one entry, we return an error targeting the association:

$Parameter/_it/_Items(...)/_PackItems

The generated MultiValueField is not highlighted in red.

Questions:

  1. Does Fiori Elements OData V4 support automatic value-state handling for validation messages targeting collection-valued associations?

  2. Is there a specific RAP %element, %path, or OData message target syntax required to associate the error with the generated MultiValueField?

  3. Should the validation message be reported against the parent entity's association or against the child entity's PackType property?

  4. Is this a known limitation of sap.ui.mdc.MultiValueField in SAPUI5?

We would prefer to use standard RAP/Fiori Elements message handling rather than manually setting the generated control's valueState.

0 Likes

Accepted Solutions (0)

Answers (1)

Answers (1)

sravan_aleshwaram
Contributor

Hello @kristof_desaegera89d83 

This is a known limitation in Fiori Elements OData V4. Validation messages targeted at a collection-valued association (_PackItems) are not automatically propagated to the generated sap.ui.mdc.MultiValueField

try,

Report the validation against a specific child field (e.g., PackItems-PackType) instead of the association.
If the error is at least one entry required use a parent-level message (page/object level)
Automatic red highlighting of MultiValueField for association-targeted RAP messages is generally not supported in current SAPUI5/Fiori Elements versions


Thanks,
Sravan

0 Likes

Hey Sravan, thank you for your response.

I was already thinking in this direction, but posted to verify.  For now, I put the message indeed on the parent element, showing a popup.  Still it's a bit confusing for the user to see all input fields in red, and the multivalue one not.

I did however already write some custom code that could filter out the specific message, and find the binded element myself.

This way I could set the UI element validation myself.

I did have some issues on resetting the validation when a user enters new data. Do you have any tips on resetting the state using oData v4 binding?