Skip to Content
Mar 15, 2017 at 06:49 AM

How to read Value of a cell from sap.ui.table.Table?

7752 Views Last edit May 24, 2020 at 11:32 AM 3 rev


I want to get the value of a cell from a sap.ui.table, when I click on that cell. This cell is having 'Link' parameter; so, when I press on the link it's firing an event. In that evnt I should be able to get that value of that cell. Below is the code.

<Column width="auto" filterProperty="Owner" defaultFilterOperator="StartsWith">
	<m:Label text="{i18n>opOwner}"/>
		<m:Link text="{tableModel>Owner}" press="handleLinkPress"/>
handleLinkPress : function(oEvent){
			var cell = "";

He in variable 'cell' I need to capture the Text of that cell.

I'm new in SAPUI5. Any help would be much appreciated. It would be very helpful if I can get the proper syntax.

Also, how to add date filter in date column.

<m:Label text="{i18n>opstartdate}"/>
		<m:Text text="{path: 'tableModel>Start_Date', type: 'sap.ui.model.type.Date', formatOptions: { pattern: 'dd/MM/yyyy' } }"/>

I've added the filter, but it's not working


Shubhrajit Chowdhury