or
Hi Telerik,
Is this Marked Zones Chart available in “2011.2 11.831 (Aug 31, 2011)” version of Windows forms
Regards
Vinodh
var table = new Table { Borders = new TableBorders(new Border(1, Telerik.WinControls.RichTextBox.Model.BorderStyle.Single, Color.Black)), LayoutMode = TableLayoutMode.Fixed, PreferredWidth = new TableWidthUnit(200) }; for (int i = 0; i < 2; i++) { var row = new TableRow(); for (int j = 0; j < 2; j++) { var cell = new TableCell { Background = Color.White, Padding = new Padding(3) }; var paragraph = new Paragraph(); var span = new Span { Text = "c"+ i + j }; paragraph.Inlines.Add(span); cell.Blocks.Add(paragraph); row.Cells.Add(cell); } table.Rows.Add(row); } this.richTextBox.InsertTable(table);
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>Untitled</title> <style type="text/css"> .p_384D933F { margin: 0px 0px 0px 0px;text-align: left;text-indent: 0pt;padding: 0px 0px 0px 0px; } .s_6BF1D20F { font-family: 'Calibri';font-style: normal;font-size: 16px;color: #000000; } .p_CC664AAA { margin: 0px 0px 12px 0px;text-align: left;text-indent: 0pt;padding: 0px 0px 0px 0px; } .tbl_77AF2C2D { border-collapse: collapse;table-layout: fixed;width: 200px; } .tc_C0034B80 { border-left: 1px solid #000000;border-top: 1px solid #000000;border-right: 1px solid #000000;border-bottom: 1px solid #000000;padding: 3px 3px 3px 3px;background-color: #FFFFFF;vertical-align: top; } </style> </head> <body> <p class="p_384D933F"><span class="s_6BF1D20F"> </span></p> <table class="tbl_77AF2C2D"> <tr> <td class="tc_C0034B80" align="left" valign="top"> <p class="p_CC664AAA"><span class="s_6BF1D20F">c00</span></p> </td> <td class="tc_C0034B80" align="left" valign="top"> <p class="p_CC664AAA"><span class="s_6BF1D20F">c01</span></p> </td> </tr> <tr> <td class="tc_C0034B80" align="left" valign="top"> <p class="p_CC664AAA"><span class="s_6BF1D20F">c10</span></p> </td> <td class="tc_C0034B80" align="left" valign="top"> <p class="p_CC664AAA"><span class="s_6BF1D20F">c11</span></p> </td> </tr> </table> <p class="p_384D933F"><span class="s_6BF1D20F"> </span></p> </body></html>IDocumentFormatProvider provider = new HtmlFormatProvider(); Byte[] convertedText = Encoding.ASCII.GetBytes(htmlStream); RadDocument document = provider.Import(convertedText); richTextBox.Document = document;Private Sub ItemDataBound(ByVal sender As Object, ByVal args As ListItemDataBoundEventArgs) Private Sub ItemDataBinding(ByVal sender As Object, ByVal args As ListItemDataBindingEventArgs) Private Sub CreatingVisualListItem(ByVal sender As Object, ByVal args As CreatingVisualListItemEventArgs) Private Sub ItemDataBound(ByVal sender As Object, ByVal args As ListItemDataBoundEventArgs) Handles RadDropDownList1.ItemDataBound, RadListControl1.ItemDataBoundPrivate Sub ItemDataBinding(ByVal sender As Object, ByVal args As ListItemDataBindingEventArgs) Handles RadDropDownList1.ItemDataBindingPrivate Sub CreatingVisualListItem(ByVal sender As Object, ByVal args As CreatingVisualListItemEventArgs) Handles RadListControl1.CreatingVisualListItemprivate void PrimaryRadGridView_CellFormatting(object sender, CellFormattingEventArgs e) { if (e.CellElement.ColumnInfo.FieldName == "ID") { e.CellElement.DrawFill = true; e.CellElement.NumberOfColors = 1; e.CellElement.BackColor = Color.LightSlateGray; e.CellElement.GradientStyle = GradientStyles.Linear; } if (e.CellElement.ColumnInfo.FieldName == "Type") { e.CellElement.DrawFill = true; e.CellElement.NumberOfColors = 1; e.CellElement.BackColor = Color.LightSlateGray; e.CellElement.GradientStyle = GradientStyles.Linear; } if (e.CellElement.ColumnInfo.FieldName == "BBor") { e.CellElement.DrawFill = true; e.CellElement.NumberOfColors = 1; //e.CellElement.ForeColor = Color.Red; e.CellElement.BackColor = Color.LightGoldenrodYellow; e.CellElement.GradientStyle = GradientStyles.Linear; } if (e.CellElement.ColumnInfo.FieldName == "EBor") { e.CellElement.DrawFill = true; e.CellElement.NumberOfColors = 1; e.CellElement.ForeColor = Color.Red; e.CellElement.BackColor = Color.LightGoldenrodYellow; e.CellElement.GradientStyle = GradientStyles.Linear; } if (e.CellElement.Value != null && e.CellElement.Value.ToString() == "PE0") { e.Row.Cells[4].ReadOnly = true; e.Row.Cells[4].Value = "XXXXXXXXXX"; e.Row.Cells[4].Style.BackColor = Color.DarkRed; e.Row.Cells[4].Style.CustomizeFill = true; } }private void PrimaryRadGridView_CellValidated(object sender, CellValidatedEventArgs e) { if (e.ColumnIndex != 3) return; if (e.RowIndex != -1) { int nextRowIndex = e.RowIndex + 1; int lastRowIndex = PrimaryRadGridView.Rows.Count - 1; if (nextRowIndex <= lastRowIndex) { var value = PrimaryRadGridView.Rows[e.RowIndex].Cells[3].Value.ToString(); PrimaryRadGridView.Rows[nextRowIndex].Cells[2].Value = value; PrimaryRadGridView.Rows[nextRowIndex].Cells[2].ReadOnly = true; PrimaryRadGridView.Rows[nextRowIndex].Cells[2].Style.ForeColor = Color.Blue; PrimaryRadGridView.Rows[nextRowIndex].Cells[2].Style.BackColor = Color.GreenYellow; PrimaryRadGridView.Rows[nextRowIndex].Cells[2].Style.CustomizeFill = true; PrimaryRadGridView.ClearSelection(); PrimaryRadGridView.SelectionMode = Telerik.WinControls.UI.GridViewSelectionMode.CellSelect; PrimaryRadGridView.Rows[nextRowIndex].Cells[3].BeginEdit(); PrimaryRadGridView.Rows[nextRowIndex].Cells[2].Style.ForeColor = Color.Blue; PrimaryRadGridView.Rows[nextRowIndex].Cells[3].Style.BackColor = Color.GreenYellow; PrimaryRadGridView.Rows[nextRowIndex].Cells[3].Style.CustomizeFill = true; } } }