Hi,
Bsed on the code below, I am facing the following issue with XamWebGrid 9.2: -
When the ColumnWidth is set to SizeToHeader, the FixedColumnIndicator overlaps last 2-3 alphabets of the column header.
It means that the column header is not completely visible. THIS WAS WORKING FINE WITH INFRAGISTICS 9.1.
Can someone suggest whats causing the problem ? or is it a issue / enhancement in 9.2?
Here is the XAML
<
UserControl xmlns:controlsToolkit="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Toolkit" xmlns:controls="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls" xmlns:igGrid="clr-namespace:Infragistics.Silverlight.Controls;assembly=Infragistics.Silverlight.XamWebGrid.v9.2" x:Class="IG_Samples.MainPage"
="http://schemas.microsoft.com/winfx/2006/xaml"
="480">
</
UserControl>
HERE IS THE CODE
using
System;
System.Collections.Generic;
System.Collections.ObjectModel;
System.Linq;
System.Net;
System.Windows;
System.Windows.Controls;
System.Windows.Documents;
System.Windows.Input;
System.Windows.Media;
System.Windows.Media.Animation;
System.Windows.Shapes;
Infragistics.Silverlight;
Infragistics.Silverlight.Controls;
Infragistics.Silverlight.Controls.Primitives;
namespace
IG_Samples
{
UserControl
>();
MainPage()
InitializeComponent();
BindData();
}
BindData()
i = 1; i <= 100; i++)
objSource.Add(
+ i.ToString() });
.igGridRequestDetails.ItemsSource = objSource;
e)
.igGridRequestDetails.ColumnTypeMappings.Count;
i = count - 1; i >= 0; i--)
))
);
?))
.Parse(chkIsActive.IsChecked.ToString())});
MyDataSource
; }
I am not sure what you are seeing with this sample, because AllowFixedColumns was set to DropArea and ColumnWidth was set to (well it was not set so it is AutoInit by default).
Under these conditions you would not see a fixed column marker. You would see a SortIndicator which would cover up the text, but this is because AutoInit sets the column width when it renders so sorting tries to shoe horn an extra UI element into a given width.
Setting the ColumnWidth to Auto would eliminate this issue.
I think my query was not clean. let me put it this way: -
1) Create a xamwebgrid 9.2
2) Set AutoGenerateColumns = false
3) Add the following columns. Keep the exact header text as mentioned below
a) TextColumn - HeaderText="ID"
b) DateColumn - HeaderText = "Date of Joining"
c) TextColumn - HeaderText = "Full Name"
d) CheckBoxColumn - HeaderText = "Is Active"
4) Grid should have the following properties set
a) Sort Settings
i) AllowSorting = "True"
ii) AllowMultipleColumnSorting = "True"
iii) ShowSortIndicator = "True"
b) FixedColumnSettings
i) AllowFixedColumns = "Indicator"
5) Set Grid's height = 300
6) Bind the grid with appropriate collection where number of records are more than 100 (just to highlight the issue more prominantly)
=> Run the page
a) Everything would look good with initial load
b) Now sort on the basis of "ID" column and see what happens to the column header
c) Same way sort on the basis of Name column and the header would be chopped off.
For exact reference you can use the following code to generate quick collection used in my sample
ObservableCollection<MyDataSource> objSource = new ObservableCollection<MyDataSource>();
for (int i = 1; i <= 100; i++)
The class structure
public class MyDataSource
public int id { get; set; }
public string joiningDate { get; set; }
public string name { get; set; }
public bool isactive { get; set; }
I hope this helps you understand the scenario properly.