Telerik Forums
UI for WPF Forum
3 answers
209 views
If I set my provider to the BingMapProvider and set the IsTileCachingEnabled to true, when I exit my application I still have threads running that stop my application from fully closing.

Setting the IsTileCachingEnabled to false at the start avoids the problem, but is there a way that I can clean up the threads being used to provide the cached tiles?

I am using your WPF control within a windows forms application using System.Windows.Forms.Integration.ElementHost

Thanks
Simon
Andrey
Telerik team
 answered on 23 Nov 2010
1 answer
50 views
I am trying to create a line chart, where the Itemmapping is done to two fields of a class and the RadControl.ItemSource is set to a List of objects of that class. The code is as follows:
SeriesMapping sm = new SeriesMapping();
            LineSeriesDefinition sd = new LineSeriesDefinition();
 
            sm.SeriesDefinition = sd;
 
            sm.ItemMappings.Add(new ItemMapping("Value",DataPointMember.YValue));
            sm.ItemMappings.Add(new ItemMapping("Time", DataPointMember.XValue));
            LineChart.SeriesMappings.Add(sm);
            LineChart.ItemsSource = GenerateLineData2(); // Returns a list of LineData objects ...

Here, the class that represents the data point looks as below

public class LineData
        {
            private double _time;
            private double _value;
            public double Time
            {
                get { return _time; }
                set { _time = value; }
            }           
            public double Value
            {
                get { return _value; }
                set { _value = value; }
            }
 
        }

The questions are
1. can I do ItemMapping if the fields 'Value' and 'Time' do not belong to the same class?
2. I have two lists of (say) double values, one for the 'Time' values and other for the 'Value' values; how can I perform the item mapping in that case?

Evgeni "Zammy" Petrov
Telerik team
 answered on 23 Nov 2010
3 answers
122 views
Hello

We where exactly following your DEMO example "grouping and aggregation" with chart and radgrid, which works fine so far.

But when we put a filter in the radgrid the values are not changing, means that the chart is always taking the full data, regardless of the filter in radgrid.

Is there a way to maintain a chart that is "listening" to the radgrid filter?

thanks Thomas
Sia
Telerik team
 answered on 23 Nov 2010
1 answer
215 views
Hi,

I need to programmatically update the sort order for a gridview, for example if I have a list of orders from different companies, in different countries for different amounts, and the user clicks on the country column to sort, I want to add the company and value columns to the sort so that within each country the orders are sorted by company, and within a company the orders are sorted by amount.

I have tried to add these as SortDescriptors in the 'Sorting' event but I cannot get the sort to use the newly added descriptors.

What technique should I be using?

Thanks,
Yavor Georgiev
Telerik team
 answered on 23 Nov 2010
2 answers
105 views
Hello,
I am evaluating Your controls and I would need the interactivity feature for charts, but I can't get it to work.
I am using WPF 4, but nothing. I tried to use the same code in a Silverlight project and there it works perfectly.
You can find my sample project with the WPF and Silverlight application under the following link:
http://www.sendspace.com/file/ap73ki

Could You please tell me what I'm doing wrong?

The only difference I noted was the different Version of the "Telerik.Windows.Controls.Charting".
WPF: 2010.2.924.35
Silverlight: 2010.2.924.1040

Regards
Gernot
Top achievements
Rank 1
 answered on 23 Nov 2010
3 answers
51 views
Hi,

I am trying to do some Geocoding using the BingSearchProvider.  I have been adding british postcodes and there are some that it doesn't like, which causes a crash that I cannot handle

For example, try

B21 0AG

in your Search Demo

If I add 

B21 0AG, Birmingham

then we just get back a Geocoded location for Birmingham as a whole. It works with similar postcodes, for example

B64 6HN
Andrey
Telerik team
 answered on 23 Nov 2010
1 answer
93 views
I am plotting a line graph with a set of test data of only 5 data points and it takes visibly long time to plot the line. Is it some kind of animated behavior that is responsible for this or I am missing something? Please help me on how I can get the line plotted in just one shot - with no visible delay between its start and end ...

The code is as follws:

The data structure that is set to the itemsource of  RadChart control is

private ObservableCollection<KeyValuePair<int, Double>> _datapoints;

The chart is initialised as below:
radchart.DefaultView.ChartArea.AxisX.AutoRange = false;
radchart.DefaultView.ChartArea.AxisX.AddRange(-100, 100, 50);
radchart.DefaultView.ChartArea.AxisX.MajorGridLinesVisibility = Visibility.Visible;
radchart.DefaultView.ChartArea.AxisY.AutoRange = false;
radchart.DefaultView.ChartArea.AxisY.AddRange(-100, 100, 50);
radchart.DefaultView.ChartArea.AxisY.MajorGridLinesVisibility = Visibility.Visible;
SeriesMapping sm = new SeriesMapping();
sm.SeriesDefinition = new LineSeriesDefinition();
sm.SeriesDefinition.ShowItemLabels = false;
sm.ItemMappings.Add(new ItemMapping("Key", DataPointMember.XValue));
sm.ItemMappings.Add(new ItemMapping("Value", DataPointMember.YValue));
radchart.SeriesMappings.Add(sm);
radchart.ItemsSource = _datapoints;

_datapoints.Add(

new KeyValuePair<int, double>(1, 10.0));

 

_datapoints.Add(

new KeyValuePair<int, double>(50, 20.9));

 

_datapoints.Add(

new KeyValuePair<int, double>(80, 80.1));

 

_datapoints.Add(

new KeyValuePair<int, double>(100, 34.8));

 



I have a button to trigger refresh on the control, who handler is as follows:

private void Refresh_Click(object sender, RoutedEventArgs e)
{           
    _datapoints[0] = new KeyValuePair<int, double>(1, Rnd.Next(-100, 100) *   Rnd.NextDouble());
    _datapoints[1] = new KeyValuePair<int, double>(50, Rnd.Next(-100, 100) * Rnd.NextDouble());
    _datapoints[2] = new KeyValuePair<int, double>(80, Rnd.Next(-100, 100) * Rnd.NextDouble());
    _datapoints[3] = new KeyValuePair<int, double>(100, Rnd.Next(-100, 100) * Rnd.NextDouble());
}

Evgeni "Zammy" Petrov
Telerik team
 answered on 23 Nov 2010
1 answer
81 views
Hi,

I would like to set a default error handling method for all of my DatePicker controls in my application. This "default error handling method" is to set the last valid value on focus lost, if the actual value cannot be parsed. This way, I would like to avoid mistyping problems.

For example if the current value is "2010-11-17" and the user types "aaa", I would like to reset the value back to "2010-11-17" on focus lost instead of clearing the value of the control.

My first idea was to set this behavior in App.xaml as part of the default style of DatePicker (by triggers). Is it possible to achieve my goal this way? Could someone please help me with an example on how to do this? If my idea is wrong, could somebody tell me how this task can be solved?
(The application is using the MVVM pattern.)


Thank you for the answer in advance,
                                                             G. M.
George
Telerik team
 answered on 23 Nov 2010
5 answers
72 views
I am displaying a large amount of timestamped data on a WPF RadGridView that has two levels of grouping.
The two indexed fields used for grouping refer to two other classes of object.
I have a value convertor that allows me to display the name field of the group object on the group header
That works very well.

I now have two needs:

1. What I would really like is that when a group header is selected a 'GroupDetail' section would expand
in the same fashion as a RowDetail so that I can display the fields of the grouping object.

2. Within my data I have some rows that are blank except for the time and an index to an event object 

DataTable

time       event   data_0 ... data_n

t0             0           x0             xn

t1             0           y0            yn

t2             e1        nul           nul

t3             0           z0            zn

The event class has different subclasses, They all have a string field but may have different sets of data fields.

I would like to be able to display each event object as a row displaying its string field on a single wide cell, like a group header without the expander.  The RowDetails for that row could then ask the event object to display its particular fields.

Thanks

Rossen Hristov
Telerik team
 answered on 23 Nov 2010
1 answer
156 views
Hello,

ASFIK there is no zoom shortcut in RadScheduleView. As slider seems to be not best solution, I'm trying to implement zoom on CTRL+MouseWheel. But RadScheduleView.MouseWheel event is never invoked.

I've done some research and found the following event handler in ScheduleViewBase

protected override void OnMouseWheel(MouseWheelEventArgs e)
{
    e.Handled = true;
    double newDelta = SystemParameters.WheelScrollLines * this.VerticalSmallChange;
    if (e.Delta > 0)
    {
        newDelta = -newDelta;
    }
    double offset = Math.Min(this.ExtentHeight, Math.Max((double) 0.0, (double) (this.VerticalOffset + newDelta)));
    this.VerticalOffset = offset;
    base.OnMouseWheel(e);
}

MouseWheel event is always handled by control itself.

Is it possible to expose it as done in RadScheduler?

Thanks,
Anatoly
Hristo
Telerik team
 answered on 23 Nov 2010
Narrow your results
Selected tags
Tags
GridView
General Discussions
Chart
RichTextBox
Docking
ScheduleView
ChartView
TreeView
Diagram
Map
ComboBox
TreeListView
Window
RibbonView and RibbonWindow
PropertyGrid
DragAndDrop
TabControl
TileView
Carousel
DataForm
PDFViewer
MaskedInput (Numeric, DateTime, Text, Currency)
AutoCompleteBox
DatePicker
Buttons
ListBox
GanttView
PivotGrid
Spreadsheet
Gauges
NumericUpDown
PanelBar
DateTimePicker
DataFilter
Menu
ContextMenu
TimeLine
Calendar
Installer and Visual Studio Extensions
ImageEditor
BusyIndicator
Expander
Slider
TileList
PersistenceFramework
DataPager
Styling
TimeBar
OutlookBar
TransitionControl
Book
FileDialogs
ToolBar
ColorPicker
TimePicker
SyntaxEditor
MultiColumnComboBox
VirtualGrid
Wizard
ExpressionEditor
NavigationView (Hamburger Menu)
DesktopAlert
WatermarkTextBox
BarCode
SpellChecker
DataServiceDataSource
EntityFrameworkDataSource
RadialMenu
ChartView3D
Data Virtualization
BreadCrumb
ProgressBar
Sparkline
LayoutControl
TabbedWindow
ToolTip
CloudUpload
ColorEditor
TreeMap and PivotMap
EntityFrameworkCoreDataSource (.Net Core)
HeatMap
Chat (Conversational UI)
VirtualizingWrapPanel
Calculator
NotifyIcon
TaskBoard
TimeSpanPicker
BulletGraph
Licensing
WebCam
CardView
DataBar
FilePathPicker
PasswordBox
Rating
SplashScreen
Accessibility
Callout
CollectionNavigator
Localization
AutoSuggestBox
VirtualKeyboard
HighlightTextBlock
Security
TouchManager
StepProgressBar
Badge
OfficeNavigationBar
ExpressionParser
CircularProgressBar
SvgImage
PipsPager
SlideView
AI Coding Assistant
+? more
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Bronze
Iron
Iron
Sergii
Top achievements
Rank 1
Iron
Iron
Dedalus
Top achievements
Rank 1
Iron
Iron
Lan
Top achievements
Rank 1
Iron
Doug
Top achievements
Rank 1
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?