Telerik Forums
UI for WPF Forum
8 answers
291 views
I have 10+ columns in my radtreelistview control

when i scroll or expand, the responding time of the control is quite slow

for example, while expanding a node, even it only has like 1 or 2 child rows, it still take a long time to load

i have tried to 'hide' most of the columns, then the responding time becomes instant

is treelistview not designed for such purpose

or is there anyway to work around this???
Tim Ge
Top achievements
Rank 1
 answered on 20 Jul 2011
13 answers
353 views

Hello

I have Combo Box column in grid with data member binding for id.

The problem that the Filter shows the Ids instead of the names

How can I show the name without change the data member binding or the filter?

See picture attached.

Best regards

Ehud.

Anthony
Top achievements
Rank 1
 answered on 20 Jul 2011
3 answers
211 views
Hi,

I need to have the ability to move the rows of a radgridview up/down without rebinding the grid. The gridview is grouped on two groups.

Is there a quick and simple way to do that?

Thanks,
Arpit
Scott
Top achievements
Rank 1
 answered on 20 Jul 2011
2 answers
53 views

Hello, we just updated our DLL's to Q2 2011 (CLR 4.0), and we noticed that the field filter drop lists are not allowing independent values.  For example, if you select "Contains" for Filter1, then Filter2 also becomes "Contains".  Likewise, if you select "Starts With" for Filter2, and Filter1 already is set to "Contains", Filter1 changes to "Starts With".

We are not overriding any functionality with Prepare, etc.

Thanks for any info.
Bob
Top achievements
Rank 3
Iron
Iron
Veteran
 answered on 19 Jul 2011
0 answers
181 views
I tried your latest demo 2010.2

The GridView has 8 Rows. Each Row has a RichTextBox as DataTypeColumn.

On the GridView the Virtualization on Columns + Rows is turned on also the Realtime scrolling.

When I drag now the thumb bar of the Scrollbar the DataRows are jumping with a delay. Seems the creating of a datarow when it is getting into the visible area is badly solved. 

What is wrong with my code and how can I improve smoothness of the scrolling ?

Using the so called crap DataGrid from Microsoft the scrolling is superb and the DataGrid is loaded 3 times faster... I just miss the features you offer...

my test code:

<telerik:RadGridView x:Name="dailyGrid" <br>                ItemsSource="{Binding PeriodListViewModel}"<br>                ScrollMode="RealTime"                 <br>                AutoGenerateColumns="False"                 <br>                CanUserDeleteRows="False"<br>                CanUserInsertRows="False"<br>                CanUserReorderColumns="False"<br>                CanUserResizeColumns="False"<br>                CanUserSortColumns="False"<br>                DataLoadMode="Asynchronous"<br>                RowStyle="{StaticResource ResourceKey=RowStyle}" <br>                RowIndicatorVisibility="Collapsed" EnableRowVirtualization="False" EnableColumnVirtualization="False"><br><br>                <telerik:RadGridView.Columns><br>                    <telerik:GridViewDataColumn Header="Content" Width="*"><br>                        <telerik:GridViewDataColumn.CellTemplate><br>                            <DataTemplate><br>                                <Grid HorizontalAlignment="Stretch"><br>                                    <Grid.RowDefinitions><br>                                        <RowDefinition Height="200" /><br>                                    </Grid.RowDefinitions><br>                                    <telerik:RadRichTextBox VerticalScrollBarVisibility="Auto" VerticalAlignment="Stretch" VerticalContentAlignment="Stretch"                                                             <br>                                                            IsSpellCheckingEnabled="False" <br>                                                              x:Name="RTFBox" /><br>                                    <telerikProvider:RtfDataProvider                                        <br>                                        Rtf="{Binding Path=Content}"<br>                                        UpdateSourceTrigger="LostFocus" <br>                                        RichTextBox="{Binding ElementName=RTFBox}" /><br>                                </Grid><br>                            </DataTemplate><br>                        </telerik:GridViewDataColumn.CellTemplate><br>                    </telerik:GridViewDataColumn>                                    <br>                </telerik:RadGridView.Columns><br>            </telerik:RadGridView>-->


btw. the DataLoadMode Async or Sync there seems no difference for me. The data is always loaded syncronously because the GridView is only visible when all data is loaded... thats not async!

bernd kopp
Top achievements
Rank 1
 asked on 19 Jul 2011
5 answers
461 views
Hello,

I want get the the Label in gridview's datacolumn celltemplate.
In xaml file , the design is as follows.

 <telerik:RadGridView x:Name="ecbPropertiesGV" AutoGenerateColumns="False"
                                                 ActionOnLostFocus="CancelEdit" CanUserReorderColumns="False"
                                                 RowIndicatorVisibility="Collapsed" IsFilteringAllowed="False"
                                                 CanUserDeleteRows="False" CanUserInsertRows="False" CanUserSelect="False"
                                                 CanUserSortColumns="False" IsReadOnly="True" ShowGroupPanel="False" CanUserResizeColumns="False">
                                <telerik:RadGridView.Columns>
                                    <telerik:GridViewDataColumn Header="Number."  x:Name="numberColumn" HeaderTextAlignment="Center">
                                        <telerik:GridViewDataColumn.CellTemplate>
                                            <DataTemplate>
                                                <Label x:Name="lblName" Width="170" VerticalAlignment="Center" />
                                            </DataTemplate>
                                        </telerik:GridViewDataColumn.CellTemplate>
                                    </telerik:GridViewDataColumn>
</telerik:RadGridView>

How to find the lblName(Label)  in GridViewDataColumn.
If anyone who knows about this , please reply me.

Best Regards
Mark Richardson
Top achievements
Rank 1
 answered on 19 Jul 2011
8 answers
209 views
Hi,

How can I define Headers style in RadGridView in code

Or

Is there any property which deals with headers styles?

Thanks,
-Narendra

Bob
Top achievements
Rank 3
Iron
Iron
Veteran
 answered on 19 Jul 2011
2 answers
154 views
My application is having an error when I try to write a manual test with the TestManager.

When running the application, the error is not generated only when recording tests.

The stacktrace of the error is this:
System.NullReferenceException: Object reference not set to an instance of an object.     at Telerik.Windows.Controls.RadTabControlAutomationPeer.GetChildrenCore() in f:\113\WPF_Scrum\Current_HotFix\Sources\Development\Controls\Navigation\TabControl\RadTabControlAutomationPeer.cs:line 207     at System.Windows.Automation.Peers.AutomationPeer.EnsureChildren()     at System.Windows.Automation.Peers.AutomationPeer.UpdateChildrenInternal(Int32 invalidateLimit)     at System.Windows.Automation.Peers.ItemsControlAutomationPeer.UpdateChildren()     at System.Windows.Automation.Peers.AutomationPeer.UpdateSubtree()     at System.Windows.Automation.Peers.AutomationPeer.UpdateSubtree()     at System.Windows.Automation.Peers.AutomationPeer.UpdateSubtree()     at System.Windows.Automation.Peers.AutomationPeer.FireAutomationEvents()     at System.Windows.ContextLayoutManager.fireAutomationEvents()     at System.Windows.ContextLayoutManager.UpdateLayout()     at System.Windows.ContextLayoutManager.UpdateLayoutCallback(Object arg)     at System.Windows.Media.MediaContext.InvokeOnRenderCallback.DoWork()     at System.Windows.Media.MediaContext.FireInvokeOnRenderCallbacks()     at System.Windows.Media.MediaContext.RenderMessageHandlerCore(Object resizedCompositionTarget)     at System.Windows.Media.MediaContext.RenderMessageHandler(Object resizedCompositionTarget)     at System.Windows.Media.MediaContext.Resize(ICompositionTarget resizedCompositionTarget)     at System.Windows.Interop.HwndTarget.OnResize()     at System.Windows.Interop.HwndTarget.HandleMessage(WindowMessage msg, IntPtr wparam, IntPtr lparam)     at System.Windows.Interop.HwndSource.HwndTargetFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)     at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)     at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)     at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)     at MS.Internal.Threading.ExceptionFilterHelper.TryCatchWhen(Object source, Delegate method, Object args, Int32 numArgs, Delegate catchHandler)


André
Top achievements
Rank 1
 answered on 19 Jul 2011
2 answers
160 views
Good morning,

I would like to use a TreeView  that's can drag and drop in  a GridView

I make the TreeView but when a want to drag and drop i have a probleme the null Exception, after   4 days i can't see the problem.

Let me show you my code to help me please.

I have a class library  LabelData  to make the database and a  data class 
 
this is my table


CREATE TABLE MyTable
(IdTable Int(2),
IdLabel Int(20),
LName char(50)
)
and my  Rows
INSERT INTO MyTable (IdTable,IdLabel,LName) VALUES (1, 200, 'firstName');
  
INSERT INTO MyTable (IdTable,IdLabel,LName) VALUES (2, 200, 'lastName');
  
INSERT INTO MyTable (IdTable,IdLabel,LName) VALUES (3, 200, 'middleName');
  
INSERT INTO MyTable (IdTable,IdLabel,LName) VALUES (4, 201, 'circuit');
  
INSERT INTO MyTable (IdTable,IdLabel,LName) VALUES (5, 201, 'series');
  
INSERT INTO MyTable (IdTable,IdLabel,LName) VALUES (6, 202, 'country');
  
INSERT INTO MyTable (IdTable,IdLabel,LName) VALUES (7, 202, 'region');
  
INSERT INTO MyTable (IdTable,IdLabel,LName) VALUES (8, 202, 'zipcode');

For make the treeview, I use  IdLabel to make like "categorie"  and i  use LName to make like "product" .

I add a heritance in on my table MyTable   GroupLabel  with the property LName


This is my class  data.cs

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
  
LNamespace LabelData
{
    public class DataProvider
    {
        LabelDataContext dc;
  
        public DataProvider()
        {
            dc = new LabelDataContext();
        }
  
        public IEnumerable<Label> GetLabel()
        {
            return from e in dc.MyTable
                   group e by e.IdLabel into gr
                   select new Label() { IdLabel = gr.Key, LName= gr };
              
        }
  
        public IEnumerable<MyTable> Get_Table()
        {
            return from p in dc.MyTable
                   select p;
  
        }
  
  
      
     }
  
    public class Label
    {
        public int IdLabel { get; set; }
        public IEnumerable<MyTable> LName{ get; set; }
    }
  
    
      
}


And this is my behind code xaml.cs

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
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;
using Telerik.Windows.Controls.GridView;
using Telerik.Windows.Controls.DragDrop;
using Telerik.Windows.Controls;
using System.Collections.ObjectModel;
using LabelData;
using Telerik.Windows.Controls.TreeView;
using System.Collections;
  
using System.Net;
  
using System.Windows.Media.Animation;
  
  
using Telerik.Windows;
  
  
LNamespace LabelMunich
{
    /// <summary>
    /// Logique d'interaction pour MainWindow.xaml
    /// </summary>
    public partial class WindowTreeView : Window
    {
        public WindowTreeView()
        {
            InitializeComponent();
            ProfilData.DataProvider dataProvider = new ProfilData.DataProvider();
            treeView1.ItemsSource = dataProvider.GetModule();
            radGridView.ItemsSource = dataProvider.Get_Table();
  
            RadDragAndDropManager.AddDropQueryHandler(radGridView, new EventHandler<DragDropQueryEventArgs>(this.RadGridView_OnDropQuery));
            RadDragAndDropManager.AddDropInfoHandler(radGridView, new EventHandler<DragDropEventArgs>(this.RadGridView_OnDropInfo)); 
  
  
        }
        private void RadRibbonButton_Click(object sender, RoutedEventArgs e)
        {
            // FAjout fa = new FAjout();
            formAjout fa = new formAjout();
            fa.Show();
            // this.ShowActivated();
        }
  
        private void radTreeView_PreviewDragEnded(object sender, RadTreeViewDragEndedEventArgs e)
        {
            e.Handled = true;
        }
  
  
        private void RadGridView_OnDropQuery(object sender, DragDropQueryEventArgs e)
        {
            e.QueryResult = (e.Options.Source as RadTreeViewItem).Item is Module;
        }
        private void RadGridView_OnDropInfo(object sender, DragDropEventArgs e)
        {
            if (e.Options.Status == DragStatus.DropComplete)
            {
                (radGridView.ItemsSource as IList<Module>).Add((e.Options.Payload as Collection<Object>)[0] as Module);
            }
        
       
    }
}

And my Xaml document

<Window x:Class="ProfilTandem.WindowTreeView"
        xmlns:northwind="clr-namespace:ProfilData;assembly=LabelData"
        xmlns:local="clr-namespace:LabelMunich"
        xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"    
        xmlns:telerikDragDrop="clr-namespace:Telerik.Windows.Controls.DragDrop;assembly=Telerik.Windows.Controls" 
        Title="MainWindow" Height="450" Width="585">
    <Window.Resources>
        <DataTemplate x:Key="Team">
            <TextBlock Text="{Binding  Path=LName}"/>
        </DataTemplate>
  
        <HierarchicalDataTemplate DataType="{x:Type northwind:Label}" ItemsSource="{Binding Path=LName}">
            <Border Width="250">
                <Grid>
                    <TextBlock  
                 Text="{Binding Path=IdLabel}" FontSize="14" FontWeight="Bold" Margin="2" >
                    </TextBlock>
                </Grid>
            </Border>
        </HierarchicalDataTemplate>
        <HierarchicalDataTemplate DataType="{x:Type northwind:GroupLabel}">
            <Grid Margin="6">
                <TextBlock Text="{Binding Path=LName}" Padding="2" />
            </Grid>
        </HierarchicalDataTemplate>
    </Window.Resources>
    <Grid>
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="*" />
            <ColumnDefinition Width="*" />
        </Grid.ColumnDefinitions>
        <Grid.RowDefinitions>
            <RowDefinition Height="Auto"/>
            <RowDefinition Height="Auto" />
        </Grid.RowDefinitions>       
          
        <telerik:RadTreeView IsDragDropEnabled="True" Grid.Column="0" Grid.Row="1"
               SelectionMode="Multiple"      IsEditable="True"  x:Name="treeView1" Margin="0,20,0,245"
                PreviewDragEnded="radTreeView_PreviewDragEnded"
      IsDragTooltipEnabled="False" ItemsSource="{Binding}"/>
  
        <StackPanel Grid.Column="1" Grid.Row="1">
            <telerik:RadGridView x:Name="radGridView"  AutoGenerateColumns="False"
          Width="400" Height="400" HorizontalAlignment="Left" telerikDragDrop:RadDragAndDropManager.AllowDrop="True" 
          DataContext="{Binding}"   ItemsSource="{Binding}">
                <telerik:RadGridView.Columns>
                    <telerik:GridViewDataColumn DataMemberBinding="{Binding Path=IdLabel}"/>
                    <telerik:GridViewDataColumn DataMemberBinding="{Binding Path=LName}"/>
  
                    </telerik:RadGridView.Columns>
            </telerik:RadGridView>
        </StackPanel>
  
    </Grid>
</Window>

This is all


When i try to drag items treeview to gridview i have exception on this line 

  (radGridView.ItemsSource as IList<Label>).Add((e.Options.Payload as Collection<Object>)[0] as Label);

The exception System.NullReferenceException was unhandled

Object reference not set to an instance of an object

Thank you for your help
Goldoni
Top achievements
Rank 1
 answered on 19 Jul 2011
1 answer
88 views
Hello,
I'm trying to bind a hierarchical RadGridView to the same DataForm on a window (n levels of children, determined at runtime).
For the first level i do:

_qcv =  new QueryableCollectionView(_entities.Countries.ToList());
radGridView1.ItemsSource = _qcv;
radDataForm1.ItemsSource = _qcv;

Everything works fine, the grid is well syncronized with the dataform.
How can i get acces to the new expanded child grids to do the same? I mean bind the itemsCollections behind those grids to the dataForm and keep them in sync? What events should i use and how should i get the child Collections?
What is the correct aproach for this kind of children/parent/dataform sync?

Thank you.
Pavel Pavlov
Telerik team
 answered on 19 Jul 2011
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
FileDialogs
Book
ToolBar
ColorPicker
TimePicker
MultiColumnComboBox
SyntaxEditor
VirtualGrid
Wizard
ExpressionEditor
NavigationView (Hamburger Menu)
WatermarkTextBox
DesktopAlert
BarCode
SpellChecker
DataServiceDataSource
EntityFrameworkDataSource
RadialMenu
ChartView3D
Data Virtualization
BreadCrumb
LayoutControl
ProgressBar
Sparkline
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
SplashScreen
Callout
Rating
Accessibility
CollectionNavigator
Localization
AutoSuggestBox
Security
VirtualKeyboard
HighlightTextBlock
TouchManager
StepProgressBar
Badge
OfficeNavigationBar
ExpressionParser
CircularProgressBar
SvgImage
PipsPager
SlideView
AI Coding Assistant
+? more
Top users last month
Bohdan
Top achievements
Rank 3
Iron
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Elliot
Top achievements
Rank 1
Iron
Iron
Iron
Sunil
Top achievements
Rank 1
Cynthia
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Bohdan
Top achievements
Rank 3
Iron
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
Elliot
Top achievements
Rank 1
Iron
Iron
Iron
Sunil
Top achievements
Rank 1
Cynthia
Top achievements
Rank 1
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?