Telerik Forums
UI for WPF Forum
2 answers
216 views
Hi Telerik Team,

I'm facing few issues in the Hierarchy  Grid View.

1. When I expand a particular node and scroll down to the end and collapse it back, I see custom formatting applied in the row loaded event of the cells (Text Alignment in particular) gets reset to the default alignment (i.e left), as seen in image1.png.
This doesnt happen when its with in the screen view and it happens only when i scroll, the values in the cells gets scattered and the screen looks awkward.

2. Another connected issue i found during scroll and collapse was the alternate row style applied in design time got applied for all consecutive rows. (image2,png)

3.When I expand a node close to the middle/bottom of the screen and view the data and collapse it back, there is an empty space (apprx 2 rows size)  appearing above that particular node..((Image3.png)
The same thing doenst happen when i scroll up with or with out collapsing the node.
Seems the row content is not redrawn properly.

Expecting a quicker reply.

thanks and regards...
NK

yenkay
Top achievements
Rank 2
 answered on 08 Jan 2010
1 answer
91 views
Hello,
    I am trying to open a dialog radwindow but nothing appears. The window should appear after the user clicks on a button in the primary window. My application is an XBAP. 
Any help would be appreciated.
Thanks
Jorge Gonzalez
Top achievements
Rank 1
 answered on 07 Jan 2010
3 answers
122 views
Hello

I want to let the user find a row by the value of a specific column
this is the scenario-
the user write a text in a TextBox
and click search
then I take the text and find the row
(((System.Data.DataView)RadGridView1.ItemsSource).Table.Select("ActivityName like '%" + txtSearch.Text + "%' ")[0]) 
now I want to select this row
how can I do it?
Milan
Telerik team
 answered on 07 Jan 2010
1 answer
165 views
This one I have to class as wierd.

Version: WPF Q3 2009 SP1  2009.3.1208.35

I have a GridView with 7 predefined columns.
3 of the columns have HeaderCellStyle defined.  They do not have ControlTemplates.  I've only applied a few property setters to change the visual appearance.

The application starts off with a large size, so there are no scroll bars visible.
First issue is here.  Sizing the application Window down by grabbing the bottom right thumb, the scroll bars do no properly appear.  I ahe to move the mouse about to get the horizontal scroll bar to appear, and it doesn't appear to be based fully on the GridView's visible size.

Second issue.  If you resize the Window, and make it as narrow as possible, and then widen it again, the styling on the last column (Receipt Application) has changed.  This column was defined without a style, and now it's somehow gotten the style from the column next to it.

Thrid issue.  If you are somehow able to size the Window down to half it's initial width, and have a Horizonal Scroll Bar.  Now, click on the Horizontal Scroller, and moved it left and right quickly.  The other two columns that didn't have styling, now magically have the styling applied!



namespace WpfApplication_DataGrid  
{  
    using System;  
    using System.Collections.Generic;  
    using System.Collections.ObjectModel;  
    using System.Windows;  
    using System.Windows.Data;  
    using Telerik.Windows.Controls;  
 
    /// <summary>  
    /// Interaction logic for Window8.xaml  
    /// </summary>  
    public partial class Window8 : Window  
    {  
        public Window8()  
        {  
            InitializeComponent();  
 
 
            Binding binding;  
 
 
            ObservableCollection<Receipt> list2 = new ObservableCollection<Receipt>();  
            list2.Add(new Receipt("HELLO", 1123, 456, 1, 8, DateTime.Today, "B"));  
            list2.Add(new Receipt("HELLO", 2123, 456, 2, 7, DateTime.Today, "B"));  
            list2.Add(new Receipt("HELLO", 3123, 456, 3, 6, DateTime.Today, "C"));  
            list2.Add(new Receipt("HELLO", 4123, 456, 4, 5, DateTime.Today, "C"));  
            list2.Add(new Receipt("WORLD", 1123, 456, 5, 4, DateTime.Today, "A"));  
            list2.Add(new Receipt("WORLD", 2123, 456, 6, 3, DateTime.Today, "B"));  
            list2.Add(new Receipt("WORLD", 3123, 456, 7, 2, null"C"));  
            list2.Add(new Receipt("WORLD", 4123, 456, 8, 1, DateTime.Today, "D"));  
            list2.Add(new Receipt("WORLD", 4123, 456, 8, 1, DateTime.MinValue, "D"));  
 
 
            binding = new Binding();  
            binding.Source = list2;  
            uxRadGridView.SetBinding(RadGridView.ItemsSourceProperty, binding);  
 
        }  
    }  
}  
 
namespace WpfApplication_DataGrid  
{  
    using System;  
    using System.ComponentModel;  
 
    public class Receipt : INotifyPropertyChanged  
    {
        #region fields  
        string _source;  
        double _amount;  
        double _associatedAmount;  
        double _allocatedAmount;  
        double _availableAmount;  
        DateTime? _receiptEffectiveDate;  
        string _receiptApplication;
        #endregion  
 
        #region ctor  
        public Receipt()  
        {  
        }  
 
        public Receipt(string source, double amount, double associatedAmount, double allocatedAmount, double availableAmount, DateTime? receiptEffectiveDate, string receiptApplication)  
        {  
            Source = source;  
            Amount = amount;  
            AssociatedAmount = associatedAmount;  
            AllocatedAmount = allocatedAmount;  
            AvailableAmount = AvailableAmount;  
            ReceiptEffectiveDate = receiptEffectiveDate;  
            ReceiptApplication = receiptApplication;  
        }
        #endregion  
 
        #region properties  
        public string Source  
        {  
            get { return _source; }  
            set 
            {  
                _source = value;  
                NotifyPropertyChanged("Source");  
            }  
        }  
        public double Amount  
        {  
            get { return _amount; }  
            set 
            {  
                _amount = value;  
                NotifyPropertyChanged("Amount");  
            }  
        }  
        public double AssociatedAmount  
        {  
            get { return _associatedAmount; }  
            set 
            {  
                _associatedAmount = value;  
                NotifyPropertyChanged("AssociatedAmount");  
            }  
        }  
        public double AllocatedAmount  
        {  
            get { return _allocatedAmount; }  
            set 
            {  
                _allocatedAmount = value;  
                NotifyPropertyChanged("AllocatedAmount");  
            }  
        }  
        public double AvailableAmount  
        {  
            get { return _availableAmount; }  
            set 
            {  
                _availableAmount = value;  
                NotifyPropertyChanged("AvailableAmount");  
            }  
        }  
        public DateTime? ReceiptEffectiveDate  
        {  
            get { return _receiptEffectiveDate; }  
            set 
            {  
                _receiptEffectiveDate = value;  
                NotifyPropertyChanged("ReceiptEffectiveDate");  
            }  
        }  
 
        public string ReceiptApplication  
        {  
            get { return _receiptApplication; }  
            set 
            {  
                _receiptApplication = value;  
                NotifyPropertyChanged("ReceiptApplication");  
            }  
        }
        #endregion  
 
        #region Interface INotifyPropertyChanged  
        public event PropertyChangedEventHandler PropertyChanged;  
 
        private void NotifyPropertyChanged(string propertyName)  
        {  
            if (PropertyChanged != null)  
                PropertyChanged(thisnew PropertyChangedEventArgs(propertyName));  
        }
        #endregion  
    }  
}  
 
<Window x:Class="WpfApplication_DataGrid.Window8" Title="Window8" 
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" 
    xmlns:local="clr-namespace:WpfApplication_DataGrid" 
    xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation" 
    Height="700" Width="900" WindowStartupLocation="CenterScreen">  
    <Window.Resources> 
        <LinearGradientBrush x:Key="ColumnHeaderBackgroundBrush" EndPoint="0.494,0.889" StartPoint="0.494,0.028">  
            <GradientStop Color="#FFE7F1FF" Offset="0"/>  
            <GradientStop Color="#FFD2E6FF" Offset="0.4"/>  
            <GradientStop Color="#FFC7DFFF" Offset="0.4"/>  
            <GradientStop Color="#FFC7DFFF" Offset="1"/>  
        </LinearGradientBrush> 
        <SolidColorBrush x:Key="CellSeperatorBorderBrush" Color="#FFB3B3B3"/>  
 
 
        <Style x:Key="GridViewHeaderCellStyle" TargetType="{x:Type telerik:GridViewHeaderCell}">  
            <Setter Property="Background" Value="{StaticResource ColumnHeaderBackgroundBrush}" /> 
            <Setter Property="BorderBrush" Value="{StaticResource CellSeperatorBorderBrush}"/>  
            <Setter Property="BorderThickness" Value="0,0,1,0"/>  
            <Setter Property="Foreground" Value="Black"/>  
            <Setter Property="FontWeight" Value="Light"/>  
            <Setter Property="FontSize" Value="12"/>  
            <Setter Property="DropMarkPen">  
                <Setter.Value> 
                    <Pen Thickness="60">  
                        <Pen.Brush> 
                            <LinearGradientBrush EndPoint="1,0.5" StartPoint="0,0.5">  
                                <GradientStop Color="#00F4F5F6" Offset="0"/>  
                                <GradientStop Color="#B2808080" Offset="0.5"/>  
                                <GradientStop Color="#00F4F5F6" Offset="1"/>  
                            </LinearGradientBrush> 
                        </Pen.Brush> 
                    </Pen> 
                </Setter.Value> 
            </Setter> 
            <Setter Property="SnapsToDevicePixels" Value="True"/>  
        </Style> 
    </Window.Resources> 
    <Grid> 
        <telerik:RadGridView xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"   
                    AutoGenerateColumns="False" 
                    x:Name="uxRadGridView" telerik:StyleManager.Theme="Office_Black">  
            <telerik:RadGridView.Columns> 
                <telerik:GridViewDataColumn IsFilterable="False" DataMemberBinding="{Binding Source}" /> 
                <telerik:GridViewDataColumn IsFilterable="False" DataMemberBinding="{Binding Amount}" /> 
                <telerik:GridViewDataColumn IsFilterable="False" Header="Associated Amount" DataMemberBinding="{Binding AssociatedAmount}" HeaderCellStyle="{StaticResource GridViewHeaderCellStyle}"/>  
                <telerik:GridViewDataColumn IsFilterable="False" Header="Allocated Amount" DataMemberBinding="{Binding AllocatedAmount}" HeaderCellStyle="{StaticResource GridViewHeaderCellStyle}"/>  
                <telerik:GridViewDataColumn IsFilterable="False" Header="Available Amount" DataMemberBinding="{Binding AvailableAmount}" HeaderCellStyle="{StaticResource GridViewHeaderCellStyle}"/>  
                <telerik:GridViewDataColumn IsFilterable="False" Header="Receipt Effective Date" DataMemberBinding="{Binding ReceiptEffectiveDate}" HeaderCellStyle="{StaticResource GridViewHeaderCellStyle}"/>  
                <telerik:GridViewComboBoxColumn IsFilterable="False" UniqueName="ReceiptApplication" Header="Receipt Application" DataMemberBinding="{Binding ReceiptApplication}" /> 
            </telerik:RadGridView.Columns> 
        </telerik:RadGridView> 
    </Grid> 
</Window> 
 
Stefan Dobrev
Telerik team
 answered on 07 Jan 2010
6 answers
291 views

Hello,

I have a Filter Row in my GridView's header. The normal behaviour of filter is to hide the unmatching rows.
But my requirement is to highlight the matching rows and unmatched rows will still be shown. I am using the following function to do that. I am trying to set the IsSelected Property of the matching records to true, which i hoped will highlight the row. But it is not doing that. Please help.

 public void ApplySelect(object sender)  
        {  
            try  
            {  
                var senderElement = sender as FrameworkElement;  
                FilterRowDescriptor newDescriptor = new FilterRowDescriptor();  
                newDescriptor.LogicalOperator = FilterCompositionLogicalOperator.And;                  
                int idx=0;  
                foreach (MainPage.BuyHeadView bhRow in this.grid.Items)  
                {  
                    TextBox txt = senderElement as TextBox;  
                    if (bhRow.CampaignName.StartsWith(txt.Text.Trim()))  
                    {  
                        this.grid.Records[idx].IsSelected = true;  
                    }  
                    idx++;                      
                }  
                  
                //headerRow.ParentGrid.FilterDescriptors.Remove(headerRow.ParentGrid.FilterDescriptors.Where(fd => fd is FilterRowDescriptor).FirstOrDefault());  
                //headerRow.ParentGrid.FilterDescriptors.Add(newDescriptor);  
            }  
            catch  
            {  
            }  
        } 
Vishnu Ram Kumar
Top achievements
Rank 1
 answered on 07 Jan 2010
1 answer
87 views
Hello
I want to split the Colums in the gridview to 2 parts, that one is fixed and the other is horizenltal scroled

how can i control those attribute  by code in xaml or c#


1 color
2 Start position
Milan
Telerik team
 answered on 07 Jan 2010
3 answers
368 views
Hi,
I'm trying to create a new ControlTemplate for styling the GroupFooterRow.
I've used Reflector to extract the ControlTemplate GridViewGroupFooterRow from the Office Black Theme.
Whilst it looks okay initially, it seems to break down when a user updates a value, or sort a column, and the entire row dissapears underneath the GridViewGroupRow.  (Both intial look and the corrupted look are in the attached images).

Several conditions have to be met for this issue to appear.
A column has be grouped (can't see the footer otherwise).
And all Coumns have to be narrower than the view point.  (ie, no horizontal scroll bar should be visible).

Obviously something is not working right, and I've known that reflector doesn't always get all the template setters.  I was wondering if I could get the original source ControlTemplates for both the GridViewGroupRow and the GridViewGroupFooterRow?

Regards.
Kalin Milanov
Telerik team
 answered on 07 Jan 2010
2 answers
159 views
Hi, I am dealing with a difficult issue, I need to manipulate thousands of rows into rad gridview control and also have accurate sorting support in the same time, the user can chage the sorting criteria after all cells within the gridview, I cannot bring all rows from a single shoot as the data package size that must be sent through the network can exceed 5 Mb and I don't want the user to be waiting a couple of minutes until all data is loaded into the grid, I would prefer to initially add the first chunk of data which will populate the first page sorted after a predefined criteria, then if the sort criteria is changed or the page is changed I can again add the correct chunk of data to be displayed by calling a method with sorting criteria and page info parameters, this is more like a custom algorithm that I though of but, is there some built in functionality that can help me acomplish this sort of operations more stylish and more adequate if I can say so, or why not more quikly? Does rad gridview have some hidden support for this type of issues?

Many thanks!

Vladu Bogdan
Top achievements
Rank 1
 answered on 07 Jan 2010
2 answers
106 views
Hi Telerik Team,

I'm binding an hierarchical GridView with both grid's data load mode set to asynchronous. The Grouping functionality in the Parent Grid works without any issues where as the child grid hangs for few minutes and closes the application. When I removed the "DataLoadMode= Asynchrous" from the child grid view properties, the grouping function works fine on all the available columns. Can you please let me know what is the issue?

FYI: Its a WPF application.

thanks and regards...
NK
HAPPY NEW YEAR 2010
yenkay
Top achievements
Rank 2
 answered on 07 Jan 2010
3 answers
401 views
Hey,

I had a pre-sales question about RadMenu.  We have a need for a menu that overflows like the standard WPF toolbar instead of wrapping.  We have a lot of windows with menus on them, and the standard wrapping behavior causes the menu to take up too much space.  I was curious if RadMenu could overflow rather than wrapping.

Thanks,

Eric
Hristo
Telerik team
 answered on 07 Jan 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
DataPager
PersistenceFramework
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
Boardy
Top achievements
Rank 2
Veteran
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
ivory
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ClausDC
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Boardy
Top achievements
Rank 2
Veteran
Iron
Benjamin
Top achievements
Rank 3
Bronze
Iron
Veteran
ivory
Top achievements
Rank 1
Iron
Iron
Rob
Top achievements
Rank 3
Bronze
Bronze
Iron
ClausDC
Top achievements
Rank 2
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?