I get the following error when I try to add a Telerik WPF Form
Project template
Adding a WFP forms triggers this and nothing added?
So I tried a WPF .NET Core template and got prompted for this"
No idea how to proceed ... just trying to create a new project?
Rob.
Dear Team,
I have a WPF app (vb.net) where i use radgridview. Virtualization is on because we have more hundreds of rows, and in the CELLLOADED event i color the cell backgrounds based on cell content.
The result is something like this: (attached: mapps.jpg)
The customer wants me to create excel output, including the colors. I browsed a lot of forums and i found multiple approaches but the result is always the same. The background is colored, but all column inherits the color of the first row. (attached: excel.jpg)
Sub ExcelExport_Colored(rgv As RadGridView)
Dim workbook As Workbook = rgv.ExportToWorkbook(New GridViewDocumentExportOptions() With {
.ExportDefaultStyles = True,
.AutoFitColumnsWidth = True,
.ShowColumnHeaders = True})
Dim dialog As SaveFileDialog = New SaveFileDialog()
dialog.DefaultExt = "xlsx"
dialog.Filter = String.Format("{1} files (*.{0})|*.{0}|All files (*.*)|*.*", "xlsx", "Excel")
dialog.FilterIndex = 1
If dialog.ShowDialog() = True Then
Dim provider = New XlsxFormatProvider()
Using output = dialog.OpenFile()
provider.Export(workbook, output)
End Using
End If
Dim excelPath2 As String = Registry.GetValue("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\excel.exe",
"Path", "Key does not exist")
Microsoft.VisualBasic.Interaction.Shell(excelPath2 & "EXCEL.EXE /e/min """ & dialog.FileName & """", AppWinStyle.NormalFocus)
End Sub
I tried other export options as well, like radgridview.export, radgridview.exporttoxlsx.. all give the same result or worse.
Can you give any advice how to achieve it? I don't insist to the icons, if i could export the data with bgcolors i would be happy already.
Thank you !!
Peter


Hi ,
In one of my wpf window I have two grids. In one grid I only have product name that lists all the products available and another grid i have product details( id, name, price etc.) and there is a add and remove button. If I select one product name add click add then it should add the details to the product details grid and also should be able to remove it. How can I implement it. Do you have any sample code?
Hello,
I am trying to get the GridViewDataColumn after mouse click.
I can notice that radGridView.CurrentCell.Column is updated on left click. So if I perform left click and then right click, the context menu is open and I have reference to the correct column.
But if Ido right click in different cells, the current cell is not updated al I have refence to the old column.
How can I get the GridViewColumn from Cursor position.
I have only the grid, I haven't any mouse arguments.
Hi there!
I would like to customize the header of GanttChart timeline, like
if it is WeekView, "2023/2" in 1st line and "1" , "8" (← it will be the first day of week) in 2nd line or
if it is MonthlyView, "2023/Q1" in 1st line and "2", "3" (← it will be the month number like "2" means Feburay) in 2nd line.
let me know how should I customize to that.
I think that I should use "Views.MonthView.MonthHeaderTemplate" function, but I have no idea how I used it.
I found this API from this following link, but I can't get detail info because it had died.
ASP.NET MVC Gantt - API Reference - Telerik UI for ASP.NET MVC
Could you please share me if there is any link in which explaination for gantt API info, how to use or which parameter should be passed.
<telerik:RadGridView x:Name="scanSessionList" Grid.Row="0" Grid.Column="0" ItemsSource="{Binding ElementName=_this, Path=ScanSessions}" Margin="0,0,0,6" ShowGroupPanel="False" ShowGroupFooters="True"> <telerik:RadGridView.GroupDescriptors> <telerik:GroupDescriptor Member="ScanSession.VehicleId" SortDirection="Ascending"> <telerik:GroupDescriptor.AggregateFunctions> <telerik:CountFunction Caption="Missions: "/> </telerik:GroupDescriptor.AggregateFunctions> </telerik:GroupDescriptor> </telerik:RadGridView.GroupDescriptors> <telerik:RadGridView.Columns> <telerik:GridViewDataColumn Header="Description" DataMemberBinding="{Binding Path=ScanSession.Tag}"/> <telerik:GridViewDataColumn Header="Start Time" DataMemberBinding="{Binding Path=ScanSession.StartTimestamp, StringFormat=d MMM yyyy HH:mm}"/> <telerik:GridViewDataColumn Header="Elapsed Time" DataMemberBinding="{Binding Path=ScanSession.Duration, Converter={StaticResource TimeSpanConverter}}"> <telerik:GridViewDataColumn.AggregateFunctions> <telerik:SumFunction/> </telerik:GridViewDataColumn.AggregateFunctions> </telerik:GridViewDataColumn> <telerik:GridViewDataColumn Header="Distance" DataMemberBinding="{Binding Path=ScanSession.DistanceTravelled, Converter={StaticResource DistanceConverter}}"/> <telerik:GridViewDataColumn Header="Avg Speed" DataMemberBinding="{Binding Path=ScanSession.AverageSpeed, Converter={StaticResource SpeedConverter}}"/> <telerik:GridViewDataColumn Header="Max Speed" DataMemberBinding="{Binding Path=ScanSession.MaximumSpeed, Converter={StaticResource SpeedConverter}}"/> </telerik:RadGridView.Columns></telerik:RadGridView>using System;using System.Collections.Generic;using System.Linq;using System.Text;using Telerik.Windows.Data;namespace Exponent.Analyzer.Performance{ public class TimeSpanSumFunction : EnumerableSelectorAggregateFunction { protected override string AggregateMethodName { get { return "TimeSpanSum"; } } protected override Type ExtensionMethodsType { get { return typeof(Aggregates); } } } public static class Aggregates { public static TimeSpan TimeSpanSum<TSource>(IEnumerable<TSource> source, Func<TSource, TimeSpan> selector) { TimeSpan sum = TimeSpan.FromSeconds(0); foreach (TimeSpan ts in source.Select(s => selector(s))) { sum = sum.Add(ts); } return sum; } }}using System;using System.Collections.Generic;using System.Linq;using System.Text;using Telerik.Windows.Data;namespace Exponent.Analyzer.Performance{ public class TimeSpanSumFunction : EnumerableAggregateFunction { protected override string AggregateMethodName { get { return "TimeSpanSum"; } } protected override Type ExtensionMethodsType { get { return typeof(Aggregates); } } } public static class Aggregates { public static TimeSpan TimeSpanSum<TSource>(IEnumerable<TimeSpan> source) { TimeSpan sum = TimeSpan.FromSeconds(0); foreach (TimeSpan ts in source) { sum = sum.Add(ts); } return sum; } }}Hi all,
I have a question regarding calculated fields and the TotalFormat option DifferenceFromPrevious: I am using dates to compare previous values and obviously the first date compare values will be empty as there is no date to compare to (see the uploaded image). I would like to be able to remove empty columns. How would I accomplish that? Also, is there an option to exclude the total columns?
Regards,
Chris

Hi all,
I´ve attached a screenshot of a behaviour within the PivotGrid I do not understand. When adding a calculated field making use of the TotalFormat "PercentDifferenceFromPrevious", the underlying column used for the calculation is formatted as percentage value? How can I overcome this issue? Changing the NumberFormat within the PropertyAggregateDescription for "Sum of Sensitivity" does not have an effect.
EDIT: Placing the calculated field "%-Diff. Sensitivity" before the "Sum of
Sensitivity" field using Drag&Drop on the values field of the
PivotFieldList eliminates this bug. I can also set the number format of
"Sum of Sensitivity" then as I wish to.
Could you suggest a walkaround for me?
Regards,
Chris

I'm attempting to add a spreadsheet to my app and so am simply running code from the demos to get it to display. If I run the code as shown below, it runs out of memory. If I comment out the RadSpreadsheetRibbon line, the spreadsheet displays just fine.
In my code-behind, I have the following line is limiting the spreadsheet to 50 x 100.
<Grid x:Name="spreadsheetLayoutRoot">
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="Auto"/>
<RowDefinition/>
<RowDefinition Height="Auto"/>
</Grid.RowDefinitions>
<telerik:RadSpreadsheetRibbon x:Name="ribbon" BackstageClippingElement="{Binding ElementName=spreadsheetLayoutRoot, Mode=OneTime}" RadSpreadsheet="{Binding ElementName=radSpreadsheet, Mode=OneTime}"/>
<Controls:RadSpreadsheetFormulaBar Grid.Row="1" RadSpreadsheet="{Binding ElementName=radSpreadsheet, Mode=OneTime}"/>
<telerik:RadSpreadsheet x:Name="radSpreadsheet" DataContext="{Binding CommandDescriptors, ElementName=radSpreadsheet}" Grid.Row="2">
<telerik:RadSpreadsheet.FormatProviders>
<Xls:XlsFormatProvider/>
<Xlsx:XlsxFormatProvider/>
</telerik:RadSpreadsheet.FormatProviders>
</telerik:RadSpreadsheet>
<Controls:RadSpreadsheetStatusBar Grid.Row="3" RadSpreadsheet="{Binding ElementName=radSpreadsheet, Mode=OneTime}"/>
</Grid>
</UserControl>
Any suggestions?