I have changed the Label on the Trackball to the data I want to display. In this case it is 4 lines. I would like to change the color of each line of text individually. I can change the color of all of the text in the label, but not on a line by line basis. Here is a snippet of my code:
ChartTrackballController trackBallController = new ChartTrackballController();trackBallController.TextNeeded += TrackBallController_TextNeeded;radChartView1.Controllers.Add(trackBallController);
private void TrackBallController_TextNeeded(object sender, TextNeededEventArgs e){ CategoricalDataPoint dataPoint1 = e.Points[0].DataPoint as CategoricalDataPoint; CategoricalDataPoint dataPoint2 = e.Points[1].DataPoint as CategoricalDataPoint; e.Element.TextAlignment = System.Drawing.ContentAlignment.MiddleLeft; e.Element.ForeColor = System.Drawing.Color.Blue; float difference = Math.Abs((float)dataPoint1.Value - (float)dataPoint2.Value); e.Text = string.Format("Line1: {0}\nLine2: {1}\nLine3: {2}\nLine4: {3}", dataPoint1.Category, dataPoint1.Value, dataPoint2.Value, difference); }
Hello,
probably this will be a really simple and stupid question but nevertheless, I am stuck.
This is what I tried to do: We store rtf in a database and are planning to use Telerik controls in the future (there is a lot of impressive software inside).
Importing the rtf-text to RichTextEditor is quite easy. I simply put the content of the database field into a string variable and import it into RichtextEditore with this code:
Private Sub ImportRtf() Dim provider As New RtfFormatProvider() content = CStr(DataGridView.CurrentRow.Cells(xx).Value) Me.RadRichTextEditor1.Document = provider.Import(content) End SubThis works perfectly.
After editing the text in RichTextEditor I need to export the new text as rtf to a string to store it in the database. I looked over the documentation and found this:
Public Function ExportToRtf(ByVal document As RadDocument) As String Dim provider As New RtfFormatProvider() Return provider.Export(document)End FunctionI tried to assign the function's return value to an another string variable:
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click Dim content1 As String = ExportToRtf() MsgBox(content1)End SubVisualStudio puts a wiggled blue line under ExportToRtf() and demanded a missing argument for the functions's parameter "document".
Please tell me where my fault is.
Thanks in advance.
P. Arnold


Hi.
In my grid I've got some columns with double values. Some of the values might be null values or Double.NaN resp.
However, in a summary row I need value counts, average and standard deviation of the values - excluding the null values!
How can I customize the grid aggregate functions to achieve this?
I experimented with GridViewSummaryItem.AggregateExpression a bit, but I don't know how to formulate an If-Condition to skip the null value row.
My code so far looks like this:
Dim avg As New GridViewSummaryRowItem()
Dim count As New GridViewSummaryRowItem()
Dim stdev As New GridViewSummaryRowItem()
For col As Integer = 2 To table.Columns.Count - 1
Dim row_cnt As New GridViewSummaryItem()
row_cnt.Name = table.Columns(col).ColumnName
row_cnt.Aggregate = GridAggregateFunction.Count
row_cnt.FormatString = "# {0}"
count.Add(row_cnt)
Dim row_avg As New GridViewSummaryItem()
row_avg.Name = table.Columns(col).ColumnName
row_avg.Aggregate = GridAggregateFunction.Avg
row_avg.FormatString = "Ø {0:F4}"
avg.Add(row_avg)
Dim row_stdev As New GridViewSummaryItem()
row_stdev.Name = table.Columns(col).ColumnName
row_stdev.Aggregate = GridAggregateFunction.StDev
row_stdev.FormatString = "σ {0:F4}"
stdev.Add(row_stdev)
Next
grd_data_.SummaryRowsBottom.Add(count)
grd_data_.SummaryRowsBottom.Add(avg)
grd_data_.SummaryRowsBottom.Add(stdev)


Hello dear,
I can save layout for more than one grid view in the same file ??, for example:
i have gv1 and gv2, i want to save layout for all grids in one file so i can do this ?? if yes let me know, thanks.
In winforms Radgridview whenever I need to create a new row I have been generating a class with members for each column like:
public class stopCreationRow { public string shipper, consignee, zip; }
Then I create and use it for adding rows like:
private void radButton35_Click(object sender, EventArgs e) { stopCreationRow newRow = new stopCreationRow(); //throughout the code set the various fields as needed newRow.consignee = "person"; newRow.shipper = "new shipper"; //then transfer everything to the proper cells GridViewDataRowInfo dataRowInfo = new GridViewDataRowInfo(this.stopCreation_grid.MasterView); dataRowInfo.Cells["consignee"].Value = newRow.consignee; dataRowInfo.Cells["shipper"].Value = newRow.shipper; //finally create the row stopCreation_grid.Rows.Add(dataRowInfo); }
My question is two fold:
1. Can I somehow use newRow from above to directly create the row?
2. Instead of created my own class, since all this information is already in the datagrid can I access the field names though a class derived from the datagrid?
Hi,
I created a Usercontrol using telerik winform controls.
How to include the created Usercontrol into telerik grid view column as Column type
regards
Subramanya Udupa
