Hi,
In my application I have text area as columns in a table. I want to enter limited characters in a row.
So that I applied cols : 20, with out giving width. But I can entering more than 20 characters in a row.
How to restrict the no of columns in a row when entering data in text area?
For this, i tried with with keyup event also.But it's working fine when I am using normal text area.But in my application I am using text area as column in a table .So that, I am not getting any alert in keyup event.
Here is my code to create table.
var oTable = new sap.ui.table.Table({
title: "Table Example",
visibleRowCount: 7,
firstVisibleRow: 3,
selectionMode: sap.ui.table.SelectionMode.Single,
toolbar: new sap.ui.commons.Toolbar({items: [
new sap.ui.commons.Button({text: "Button in the Toolbar", press: function() { alert("Button pressed!"); }})
]}),
extension: [
new sap.ui.commons.Button({text: "Button in the Extension Area", press: function() { alert("Button pressed!"); }})
]
});
oTable
.addColumn(new sap.ui.table.Column(
{
label : new sap.m.Label({
text : "C. Behaviours"
})
.addStyleClass('noMargin noPadding fontSmall'),
template : new sap.m.TextArea(
{
rows : 3,
cols : 20,
// width : '100%',
placeholder : "HOW the employee demonstrated Fortescue\'s Values whilst achieving the role/business objectives.",
maxLength : 500,
editable : true,
}).bindProperty("value",
"values"),
sortProperty : "values",
filterProperty : "values",
width : "30%",
resizable : false,
}));
Please help me to solve this.
Thanks&Records
Sridevi