Telerik Forums
UI for WPF Forum
1 answer
84 views

Hi
I have a data table which contain round about 25 columns but i just want to show the 10 columns out of those in the RAD Carousel Control. Can you please guide me on how can i  achieve this functionality

Vlad
Telerik team
 answered on 25 Oct 2010
3 answers
117 views
Hi,
is it possible to have some kind of automatic page scrolling, so that the last added item is always visible?

I mean, while the software continues to add items, and the items reach the bottom of the grid, then you can't see the new items added unless you continuously scroll down *each new item added*!
The behaviour I want is that the grid automatic scroll down, letting the last item inserted to stay visible at the bottom of the page: is thi possible?

Thanks
Vlad
Telerik team
 answered on 25 Oct 2010
3 answers
118 views
when I MultipleSelect userContorl   or RadGridView Multiple Select rows  is   error  System.NullReferenceException

please help me : 
error message

"   in System.Windows.Automation.Peers.AutomationPeer.EnsureChildren()\r\n 
in System.Windows.Automation.Peers.AutomationPeer.GetChildren()\r\n  
in System.Windows.Automation.Peers.AutomationPeer.isDescendantOf(AutomationPeer parent)\r\n 
in System.Windows.Automation.Peers.AutomationPeer.isDescendantOf(AutomationPeer parent)\r\n
在 System.Windows.Automation.Peers.AutomationPeer.isDescendantOf(AutomationPeer parent)\r\n
在 System.Windows.Automation.Peers.AutomationPeer.isDescendantOf(AutomationPeer parent)\r\n
在 System.Windows.Automation.Peers.AutomationPeer.isDescendantOf(AutomationPeer parent)\r\n 
在 System.Windows.Automation.Peers.AutomationPeer.isDescendantOf(AutomationPeer parent)\r\n 
在 System.Windows.Automation.Peers.AutomationPeer.isDescendantOf(AutomationPeer parent)\r\n
在 System.Windows.Automation.Peers.AutomationPeer.isDescendantOf(AutomationPeer parent)\r\n 
在 System.Windows.Automation.Peers.AutomationPeer.isDescendantOf(AutomationPeer parent)\r\n
在 System.Windows.Automation.Peers.AutomationPeer.isDescendantOf(AutomationPeer parent)\r\n 
在 System.Windows.Automation.Peers.AutomationPeer.isDescendantOf(AutomationPeer parent)\r\n 
在 System.Windows.Automation.Peers.AutomationPeer.isDescendantOf(AutomationPeer parent)\r\n
在 System.Windows.Automation.Peers.AutomationPeer.isDescendantOf(AutomationPeer parent)\r\n
在 System.Windows.Automation.Peers.AutomationPeer.isDescendantOf(AutomationPeer parent)\r\n
在 System.Windows.Automation.Peers.AutomationPeer.isDescendantOf(AutomationPeer parent)\r\n
在 System.Windows.Automation.Peers.AutomationPeer.isDescendantOf(AutomationPeer parent)\r\n
在 System.Windows.Automation.Peers.AutomationPeer.isDescendantOf(AutomationPeer parent)\r\n 
在 System.Windows.Automation.Peers.AutomationPeer.ValidateConnected(AutomationPeer connectedPeer)\r\n
在 System.Windows.Automation.Peers.AutomationPeer.AutomationPeerFromInputElement(IInputElement focusedElement)\r\n 
在 System.Windows.Automation.Peers.AutomationPeer.RaiseFocusChangedEventHelper(IInputElement newFocus)\r\n
在 System.Windows.Input.KeyboardDevice.ChangeFocus(DependencyObject focus, Int32 timestamp)\r\n
在 System.Windows.Input.KeyboardDevice.TryChangeFocus(DependencyObject newFocus, IKeyboardInputProvider keyboardInputProvider, Boolean askOld, Boolean askNew, Boolean forceToNullIfFailed)\r\n
在 System.Windows.Input.KeyboardDevice.Focus(DependencyObject focus, Boolean askOld, Boolean askNew)\r\n
在 System.Windows.Input.KeyboardDevice.Focus(IInputElement element)\r\n 
在 System.Windows.UIElement.Focus()\r\n 
在 Telerik.Windows.Controls.GridView.EditContext.OnCellMouseDown(GridViewCell cell)
位置 c:\\Builds\\WPF_Scrum\\Release_WPF\\Sources\\Development\\Controls\\GridView\\GridView\\GridView\\Editing\\EditContext.cs
:line 292\r\n
在 Telerik.Windows.Controls.GridView.GridViewCell.OnMouseLeftButtonDown(MouseButtonEventArgs e)
位置 c:\\Builds\\WPF_Scrum\\Release_WPF\\Sources\\Development\\Controls\\GridView\\GridView\\GridView\\Cells\\GridViewCell.cs:行号 370\r\n
在 System.Windows.UIElement.OnMouseLeftButtonDownThunk(Object sender, MouseButtonEventArgs e)\r\n
在 System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget)\r\n
在 System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)\r\n
在 System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)\r\n
在 System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)\r\n
在 System.Windows.UIElement.ReRaiseEventAs(DependencyObject sender, RoutedEventArgs args, RoutedEvent newEvent)\r\n 
在 System.Windows.UIElement.CrackMouseButtonEventAndReRaiseEvent(DependencyObject sender, MouseButtonEventArgs e)\r\n 
在 System.Windows.UIElement.OnMouseDownThunk(Object sender, MouseButtonEventArgs e)\r\n
在 System.Windows.Input.MouseButtonEventArgs.InvokeEventHandler(Delegate genericHandler, Object genericTarget)\r\n
在 System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)\r\n 
在 System.Windows.RoutedEventHandlerInfo.InvokeHandler(Object target, RoutedEventArgs routedEventArgs)\r\n
在 System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)\r\n
在 System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)\r\n
在 System.Windows.UIElement.RaiseEvent(RoutedEventArgs args, Boolean trusted)\r\n
在 System.Windows.Input.InputManager.ProcessStagingArea()\r\n 
在 System.Windows.Input.InputManager.ProcessInput(InputEventArgs input)\r\n
在 System.Windows.Input.InputProviderSite.ReportInput(InputReport inputReport)\r\n
在 System.Windows.Interop.HwndMouseInputProvider.ReportInput(IntPtr hwnd, InputMode mode, Int32 timestamp, RawMouseActions actions, Int32 x, Int32 y, Int32 wheel)\r\n 
在 System.Windows.Interop.HwndMouseInputProvider.FilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)\r\n  
在 System.Windows.Interop.HwndSource.InputFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)\r\n
在 MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)\r\n
在 MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)\r\n
在 System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Boolean isSingleParameter)\r\n
在 System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Boolean isSingleParameter, Delegate catchHandler)\r\n 
在 System.Windows.Threading.Dispatcher.WrappedInvoke(Delegate callback, Object args, Boolean isSingleParameter, Delegate catchHandler)\r\n 
在 System.Windows.Threading.Dispatcher.InvokeImpl(DispatcherPriority priority, TimeSpan timeout, Delegate method, Object args, Boolean isSingleParameter)\r\n  
在 System.Windows.Threading.Dispatcher.Invoke(DispatcherPriority priority, Delegate method, Object arg)\r\n 
在 MS.Win32.HwndSubclass.SubclassWndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam)\r\n  
在 MS.Win32.UnsafeNativeMethods.DispatchMessage(MSG& msg)\r\n 
在 System.Windows.Threading.Dispatcher.PushFrameImpl(DispatcherFrame frame)\r\n
在 System.Windows.Threading.Dispatcher.PushFrame(DispatcherFrame frame)\r\n
在 System.Windows.Threading.Dispatcher.Run()\r\n 
在 System.Windows.Application.RunDispatcher(Object ignore)\r\n 

Yordanka
Telerik team
 answered on 25 Oct 2010
3 answers
67 views
Hi

when clicking on Automatic in the ColorPicker control included in my xaml as follows:

<telerik:RadColorPicker SelectedColorChanged="RadColorPicker_SelectedColorChanged" Tag="Foreground" Margin="5 0 5 0"/>

a System.NullReferenceException is thrown.

Sincerely.
Viktor Tsvetkov
Telerik team
 answered on 25 Oct 2010
1 answer
238 views
I have a listbox that shows dates, when a user clicks on a specific date I want it to become editable. So when I click on the listbox item, a trigger switches its datatemplate from a template containing a textblock to a template containing a RadDatePicker.

When this occurs, the RadDatePicker immediatley updates the binding source with the value.  Why is this?  The WPF Toolkit date picker does not do this, but I'd have to use the RadDatePicker.

Because I am using entity framework self tracking entities, this immediatley marks the entity I've bound to as modified.

Does anyone know a way to stop the RadDatePicker updating the binding source as soon as it appears on a datatemplate?

I've recreated this problem in a test window.  The XAML looks like this:

<Window x:Class="RadDatePickerInTemplate.MainWindow"
        Title="MainWindow" Height="350" Width="525">
    <Window.Resources>
        <DataTemplate x:Key="ViewTemplate">
            <StackPanel Orientation="Horizontal">
                <TextBlock Text="{Binding Path=Title}" />
                <TextBlock Text="{Binding Path=Date}" />
            </StackPanel>
        </DataTemplate>
        <DataTemplate x:Key="EditTemplate">
            <StackPanel Orientation="Horizontal">
                <TextBox Text="{Binding Path=Title, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" />
                <telerik:RadDatePicker SelectedDate="{Binding Path=Date, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" />
            </StackPanel>
        </DataTemplate>
        <Style x:Key="ContainerStyle" TargetType="{x:Type ListBoxItem}">
            <Setter Property="ContentTemplate" Value="{StaticResource ViewTemplate}"/>
            <Style.Triggers>
                <Trigger Property="IsSelected" Value="True">
                    <Setter Property="ContentTemplate" Value="{StaticResource EditTemplate}"/>
                </Trigger>
            </Style.Triggers>
        </Style>
    </Window.Resources>
    <Grid>
        <ListBox x:Name="MyListBox"
                 IsSynchronizedWithCurrentItem="True" 
                 ItemContainerStyle="{StaticResource ContainerStyle}" />
    </Grid>
</Window>

... and the .cs looks like:

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
  
namespace RadDatePickerInTemplate
{
    /// <summary>
    /// Interaction logic for MainWindow.xaml
    /// </summary>
    public partial class MainWindow : Window
    {
        public MainWindow()
        {
            InitializeComponent();
  
            // Show a list of Dates
            MyListBox.ItemsSource = new List<ListItem>()
            {
                new ListItem() { Title = "Test 1", Date = new DateTime(2010, 3, 27) },
                new ListItem() { Title = "Test 2", Date = new DateTime(2010, 8, 19) },
                new ListItem() { Title = "Test 3", Date = new DateTime(2010, 2, 3) }
            };
        }
    }
  
    public class ListItem
    {
        public string Title { get; set; }
  
        private DateTime _date;
        public DateTime Date
        {
            get { return _date; }
            set
            {
                // Set a breakpoint here once the form is displayed, 
                // clicking a listbox row will immediatley break here
                _date = value;
            }
        }
    }
}

Thanks for any help!
Simon.
Kaloyan
Telerik team
 answered on 25 Oct 2010
3 answers
182 views
Hi,

I am using a RadChart control with multiple RadChartAreas defined. I wanted to show individual legends belonging to each Chart area but they aren't visible. Even though I followed the examples but couldn't get the legends to display.

Here's my source code:

<telerik:RadChart x:Name="LineChartCusips" ScrollViewer.CanContentScroll="True">
                    
                    <Grid Margin="0,0,10,0">
                        <Grid.RowDefinitions>
                            <RowDefinition Height="Auto" />
                            <RowDefinition Height="*" />
                            <RowDefinition Height="Auto" />
                            <RowDefinition Height="*" />
                        </Grid.RowDefinitions>
                        <Grid.ColumnDefinitions>
                            <ColumnDefinition Width="5*" />
                            <ColumnDefinition Width="2*" />                            
                        </Grid.ColumnDefinitions>
                        <telerik:ChartTitle Grid.Row="0"  
                                            Grid.ColumnSpan="2"
                                            Content="Year 2010"
                                            HorizontalAlignment="Center"                                            
                                            Style="{StaticResource CustomTitleStyle}"/>
                        
                        <telerik:ChartArea Grid.Row="1"
                                           Grid.Column="0"
                                           Grid.ColumnSpan="2"
                                           Padding="5,10,20,5"
                                           x:Name="splineChartArea"
                                           LegendName="splineLengend"                                           
                                           ItemToolTipOpening="splineChartArea_ItemToolTipOpening"/>

                        
                        <telerik:ChartTitle Grid.Row="2"
                                            Content="Monthly Distribution"
                                            Grid.ColumnSpan="2"
                                            HorizontalAlignment="Center"
                                            Style="{StaticResource CustomTitleStyle}"/>
                        
                        <telerik:ChartArea Grid.Row="3"
                                           Grid.Column="0"
                                           x:Name="barChartArea"
                                           LegendName="barLegend"
                                           ItemToolTipOpening="ChartArea2_ItemToolTipOpening"/>
                        
                        <telerik:ChartArea Grid.Row="3"
                                           Grid.Column="1"
                                           x:Name="pieChartArea"
                                           />
                      
                                                
                    </Grid>

For one of the chart areas, splineLengend, here's the code behind:
DataSeries newSeries = new DataSeries();
                newSeries.LegendLabel = tranchedata.Key.ToString();
                newSeries.Definition = new LineSeriesDefinition();
                newSeries.Definition.InteractivitySettings.HoverScope = InteractivityScope.Series;
                newSeries.Definition.InteractivitySettings.SelectionScope = InteractivityScope.Series;                
                newSeries.Definition.ShowItemLabels = true;
                newSeries.Definition.ShowItemToolTips = true;

Thanks,
Farhan
Yavor
Telerik team
 answered on 25 Oct 2010
0 answers
100 views

Several weeks before the official release we wanted to give a preview of some of the major new controls and features coming in Q3 2010.

The new ScheduleView control for WPF 

As we announced in the beginning of this quarter we started working on a brand new scheduling component. Now that the first bits appeared you can find the new ScheduleView in the RadControls for WPF bundle. We decided to develop this new control as we wanted to prepare a really advanced Scheduling control that would fit in any application scenario. You can review the major features of the control on its product page. You can expect identical behavior, featureset and API for the ScheduleView for Silverlight that will officially come shortly after Q3 2010. 

Data Virtualization

With our 2010 Q3 Beta release we are introducing the concept of Data Virtualization - a new extension to our LINQ based data engine. The Data Virtualization technique ensures great performance and user experience improvements especially when dealing with very large datasets. The “heart” of Data Virtualization is the VirtualQueryableCollectionView class, which is responsible for loading on demand the needed chunks of data to the client. 

Data virtualization enables smooth scrolling experience in all data bound controls, which makes the components responsive all the time regardless the amount of data you present. To work properly you should use controls with UI virtualization like RadGridViewRadTreeViewRadBookRadComboBox.

Sparklines

Sparklines are used for quick graphical data visualization in the context of words, numbers or images. Their simple design and clear readability are the best way to present important business or other trends. The Sparklines are designed to be very small in size so they can perfectly fit in any text or simple grid along with other numeric data.

You can download the installation files under your accounts. The files are marked with Q3 2010 Beta.

Online demos are available at:
RadControls for WPF

We will greatly appreciate your feedback in this Beta forum.

Telerik Admin
Top achievements
Rank 1
Iron
 asked on 25 Oct 2010
2 answers
249 views

The default scrolling behavior of a ListBox is that the scrolling goes by one item at a time. The scrolling is not smooth but as you scroll the ListBox jumps to the next item. Although if you want to you can get the ListBox to scroll smoothly by setting ScrollViewer.CanContentScroll="False".

 

The RadGridView seems to have the opposite default scrolling behavior. The RadGridView scrolls smoothly in both vertical (rows) and horizontal (columns) directions.

 

Is it possible to make the RadGridView scoll by one row or column at a time, like the ListBox does by default with its items?

 

I've tried setting ScrollViewer.CanContentScroll="True" but without luck.

haagel
Top achievements
Rank 1
 answered on 25 Oct 2010
1 answer
81 views
WPF VS2010

OK, I read through everything I could find and could not find the answer I was looking for.  How can I add an item to the list of options?  I don't want to completely create a new filter control but I want to add "Is Null", "Is Not Null" to the list of choices.  Is that possible?
Vlad
Telerik team
 answered on 25 Oct 2010
1 answer
171 views

I use a RadGridView to show data. The user is allowed to sort by any column by clicking it, using the built-in sorting feature. This works fine.

 

The problem occurs when the rows in the gridview are replaced. The gridview is always filled with rows after the user has done a search. However, the new rows are not sorted in the specified way.

 

Example:

The user does a search which fills the gridview with rows.

The user clicks the header of column A to sort by that column.

The user does a new search which fills the gridview with new  rows.

The gridview now still indicates that is is sorted by column A, but the rows are NOT sorted in that way

 

Is this a bug or "by design"? Is there any way to solve my problem?

 

If no better solution exist, I was thinking that maybe I can manually tell the gridview to sort the rows according to its current sorting state after I have filled it with new rows. But I cannot find a way to do that neither...

Vlad
Telerik team
 answered on 25 Oct 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
Security
VirtualKeyboard
HighlightTextBlock
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?