Skip to Content

Error adding Column to table

Apr 23 at 05:51 PM


avatar image

So I followed this tutorial: and ran into a problem I am hoping someone can help with.

oTable.addColumn(new sap.ui.table.Column({ 
       label: v['Month'], 
       template: new sap.ui.commons.TextField({value: "{AUG}"}), 
       hAlign:"Center", resizable:false })); 

I wrote the above, which is obviously not exactly as the tutorial but I am getting the following error message "Uncaught TypeError: Cannot read property 'TextField' of undefined".

Any ideas why that would happen?

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Craig Davison Apr 23 at 06:23 PM

Found the solution by looking at the actual example of the tutorial on jsbin (which is unfortunatly blocked by corporate firewall).

I had not added the common and table libraries to the index.html.

10 |10000 characters needed characters left characters exceeded