cancel
Showing results for 
Search instead for 
Did you mean: 

How to put legend in case of sap.m.table based on diffrent colors

former_member338801
Participant
0 Kudos
938

Hi Experts,

I have to add legend for information present in the table. For example green color text says some reason 1, yellow color says some reason2 etc.. Where can I put something to show the reasons of the colors visible in the cell.

I could see class sap.viz.ui5.types.Legend has been already deprecated. Any simple way to show in the footer or on the header side of the table.

former_member338801
Participant
0 Kudos

Looks like attached screenshot.

legend-example.png

View Entire Topic
0 Kudos

Hello Raju,

Try sap.m.Table header toolbar with content of InfoLabel's (sap.tnt.InfoLabel).

Thanks,

Kumar

former_member338801
Participant
0 Kudos

thanks Gautham

For Now I have used Icon and Text that gives close to that look but I don't know if we have any better option.

<core:Icon id="iconId" src="sap-icon://border" size="10px" color="black" backgroundColor="yellow" width="auto" height="auto"/>
     <Text class="legendText" id="legendId" text="Mention your text descripotion" textAlign="Left" width="40%"/>