Hi,
When I tried set "bold" in a word in a cell of WinGrid, he display the text without formatting.
e.Row.Cells(
"Nome").Value = "<b>Nome do Produto:</b> Teste "
DisplayCellStyle is set "FormattedText".
Help me please
The FormattedLinkEditor which is used in the grid for formatted text doesn't support just having a vertical scrollbar. But if you want to turn on scrollbars inside the formatted cell, you could do this using properties on the editor.
private void ultraGrid1_InitializeLayout(object sender, Infragistics.Win.UltraWinGrid.InitializeLayoutEventArgs e) { UltraGridLayout layout = e.Layout; UltraGridBand band = layout.Bands[0]; UltraGridColumn column = band.Columns["String 1"]; column.Style = Infragistics.Win.UltraWinGrid.ColumnStyle.FormattedTextEditor; FormattedLinkEditor formattedLinkEditor = new FormattedLinkEditor(); formattedLinkEditor.ScrollBarDisplayStyle = Infragistics.Win.UltraWinScrollBar.ScrollBarDisplayStyle.Always; column.Editor = formattedLinkEditor; }
I need a vertScrollBar for my formatted cells.
Please could you tell me how can I achieve it.
patriciarosa said:1) After setting up the cells, they allow "multline" even if the property "CellMultiLine" is set to false. How do I block this?
I don't know what's causing that, so I'm afraid I cannot tell you how to stop it. I tested this out with a column whose Style is set to FormattedText and the CellMultiline property works just fine for me.
patriciarosa said:2) Is it possible to increase the height of the cell as the text did not fit in most standard height?
Yes, you can set the Height property on the row.
patriciarosa said:3) If not, is there any way to enable scroll bars (vertical) within the cell?
There's a property on the column called VertScrollBar. But this will only work for a cell that is in edit mode. And it is not supported for FormattedText cells, only for normal edit cells.
Thank you for your reply.
1) After setting up the cells, they allow "multline" even if the property "CellMultiLine" is set to false. How do I block this?2) Is it possible to increase the height of the cell as the text did not fit in most standard height?3) If not, is there any way to enable scroll bars (vertical) within the cell?
Tks
There is no DisplayCellStyle in the grid. My guess is that you meant CellDisplayStyle. But that's the wrong property and has nothing to do with formatting text with XML.
The property you want is the Style property of the column.