when you define first column as type TextArea, you must provide a TextArea object in the first argument of addRow(), same as colum2, where you define type “String”, and “Demo1” is fine here.
Mani
Hi,
Sorry, my previous answer was probably way too short, was just explaining why you encountered the error described.
Don’t know what you inted to achieve.
a “Grid” per default is not a “Table”, which allows to configure cells to consist of arbitrary Vaadin controls,
but a control with very specific assumptions, but as long as they fit to your need, it manages this in a very versatile way.
Data in the cells is managed via Renderers and Converters. The default renderer is the TextRenderer which converts the data #asString(), this is what you see. As with “Label” this renderer puts everything into one line (as it escapes all angular brackets, and html ignores line feeds). So it might be easiest if you use the HtmlRenderer, which even gives you the option to format your html with further effects; anyway etc. will work.
If you want to see multi line text, please remember that every row in a Grid has to be of the same size. The height of a row can be specified via css.