• Selection behavior on XamTilesControl with Attached properties

    XamTilesControl is a derived ItemsControl and does not support selection. If you want to have the notion of selected item(s) you can achieve this by using attached properties. Creating attached properties can extend the functionality of the XamTilesControl and the Tiles to create a simple selection behavior for the XamTilesControl.

    Behavior class: (actual code is omitted because of length)

    SelectionAdvisor : Depend…

    • Tue, Sep 7 2010
  • Setting the FieldSettings and FieldLayoutSettings of XamDataGrid

    Global settings VS Local Settings

    A complete sample project you may find here : 

    • Fri, Aug 27 2010
  • How To: Export images from the XamDataGrid to Excel Worksheet

    The DataPresenterExcelExporter component is used to export the values of the cells into an Excel document. If you have an Image column in your XamDataGrid, the path of the Image will be exported rather than the image itself.

    One way to export the actual image rather than its path is to handle the cell exporting events of the Excel exporter and add the image in the Worksheet. The Image in the Worksheet is represented as…

    • Wed, Jul 28 2010
  • HowTo : Common headers in the XamDataGrid

     

    1. Set the AutoGenerateFields and AutoArrangeCells properties of the FieldLayoutSettings to respectively False and Never:

                <igDP:XamDataGrid.FieldLayoutSettings>
                    <igDP:FieldLayoutSettings AutoGenerateFields="False" AutoArrangeCells="Never" />
                </igDP:XamDataGrid.FieldLayoutSettings>

    2. Define the FieldLayout and explicitly position each field, by setting the Row, RowSpan…

    • Wed, Jun 2 2010
  • Visual Studio code snippets for creating fast and easy data sources

    If you have to reuse the same code over and over again in different projects, the Visual Studio provides a nice feature for this - "IntelliSense Code Snippets".
    For example, as you all know, you can create a constructor for a class by typing "ctor" inside that class 

     This is a pretty simple code snippet, but you can expand it and create more complex ones and reuse this code within few key strokes…

    • Mon, May 31 2010
  • Displaying Selection Count by Implementing Custom Summary Calculators

     

         The XamDataGrid has five built-in summary calculators – Sum, Average, Maximum, Minimum and Count. You can implement additional custom summary calculators by  inheriting the abstract SummaryCalculator class. You can see a full walkthrough here in o ur help. You can take advantage of this feature and implement functionality that is not related to the XamDataGrid’s data in an efficient way. For example, you can…

    • Thu, Apr 29 2010
  • Tetris Mode

     

    The XamDataGrid is a great control that has all the most daily used functionalities like Sorting, Grouping, Filtering, Data Value History, etc.
    It gives you full control over conditional formatting and data management, great performance and responsiveness in updating data so why not have some fun with it and put it into   and break some lines of squares.

     

     

     

    • Mon, Apr 12 2010
  • Josh Smith's ListViewDragDropManager for XamDataGrid

    I am not going to invent the wheel. Josh Smith already did. I am just going to make it fit another car - the XamDataGrid.

    As Josh says, the code is fairly complex to be explained (It just works) so please refer to his article for more information on the code.

    I added one little new feature - a thin Line indicating between which records you are about to drop the dragged item. Also, I made some code changes here and…

    • Tue, Mar 23 2010
  • Commit changes when the value of editor changes

    All of the ValueEditors that are used inside or outside the XamDataGrid by default have two modes - in EditMode and out of EditMode. The values are not committed until the value editor has ended its edit mode. When the value editors are embedded in the XamDataGrid they end edit mode when they lose focus or when the enter key is pressed.

     

    If you want this value to be committed when the value is changed, then you have to…

    • Fri, Mar 12 2010
  • Setting GroupByRecordPresenter's Background

    Why is not the background of the GroupByRecordPresenter now changing when I set its Background property?

     

    This is because the Background of the Record Content Site (where the description is) of the GroupByRecordPresenter is bound to the current theme's LabelBackground brush with the following binding : Background="{DynamicResource {ComponentResourceKey {x:Type igDP:XamDataGrid}, LabelBackground}}". Only the area…

    • Tue, Feb 9 2010
  • HOWTO: Using WPF Converters to style the XamDataGrid

    There have been a lot of forums posts and questions about how to use Converters and how to bind them to the a cell, multiple cells, or something else.

    I have tried to summarize all of these requirements in one place and would be happy to update the sample project on your feedback.

    How WPF Value Converters work : they are classes (that implement IValueConverter or IMultiValueConverter interfaces) that provide the ability…

    • Tue, Jan 12 2010
  • Add-New-Record for any type of collection bound to the XamDataGrid

    Currently, the XamDataGrid supports the AddNewRecord functionality for only collections which implement the IBindingList interface( like BindingList<T> and DataView). With couple of easy tricks and few lines of code, you can achieve a similar functionality for any collection:

    1. Distinguish between a normal record and the add record - use the Tag property.

    2. Fix the Add New Record so that it looks like the real…

    • Mon, Nov 23 2009
  • Customizing XamDockManager's Floating Panes

    Many have asked the question - "What do I need to customize the Floating pane and specifically how to remove the border?". There are two main things you need to do to achieve that:

    1. Set the UseOSNonClientArea property of the ToolWindow to false.

    You can do that in the ToolWindowLoaded event of the XamDockManager like this:

     void OnToolWindowLoaded(object sender, Infragistics.Windows.DockManager.Events.PaneToolWindowEventArgs…

    • Tue, Nov 10 2009
  • How to Rename the TabItems of the XamTabControl runtime like Excel

    Excel-like renaming of the Sheets is a cool feature on a TabControl.

    You can implement this with the XamTabControl really fast and easy. Here are the steps how to do this:

    1. Retemplate the TabItemEx element and replace the ContentPresenter with a XamTextEditor. The XamTextEditor is handy in this scenario as it has cancelable events which will prevent the editor in entering edit mode if the user is single-clicking.…

    • Thu, Oct 1 2009
  • Drag & Drop with DataPresenter family controls

    This is a sample implementation how to Drag and Drop DataRecord for controls from the DataPresenter family controls - XamDataPresenter, XamDataGrid, XamDataCarousel. The sample uses the standard WPF events for drag-drop. The Drag&Drop preview is displayed in the Adorner layer.

    To enable drag-drop functionality, first you need to allow it, by setting the AllowDrop property of the element that you wish to drop over…

    • Tue, Jul 28 2009
  • XamDataGrid Sudoku

    As a side project of mine, I started working on a Sudoku game. While trying to make this game different than the others that I found in the Internet, I decided to give it a little bit of 3D look.

    For the 3D effects, I used the ContentPresenter3D control from the Thriple library. This is a really great and powerful dll for 3d support, which you can find it here (thanks to Josh Smith and Dr. WPF, hope not forgetting someone…

    • Sat, Jul 25 2009
  • ContextMenus, ToolTips, Mouse Clicks & Utilities

    This is going to be a sample about Context Menus, ToolTips on different parts of the XamDataGrid. Creating a different ContextMenu or ToolTip for any part of the XamDataGrid in code behind is more flexible that a xaml defined one, despite the fact that the WPF Binding Engine is quite capable itself.

    I. The first step is to register/hook up the events to the elements that we are interested in (CellValuePresenter, DataRecordPresenter…

    • Wed, Jul 22 2009
  • Shortcut Delete Button on XamDataGrid

    I am goint to show you how to create a shortcut button to delete records in the last field of a XamDataGrid. To do that, I am going to use an UnboundField with a custom CellValuePresenterStyle. This style has a custom Template with the Delete Icon inside the ControlTemplate. When this Image is clicked, the selected DataRecord will be deleted.
     
    <Style TargetType="{x:Type igDP:CellValuePresenter}" x:Key=…
    • Tue, Jul 14 2009
  • Vista-like Tab Preview

    Vista Operating System has a TaskBar items preview. A small popup displays the content of that window. Most of the browsers also have that if you install some plug-ins.

    I think that is a pretty handy and cool feature to see what's in a Container by hovering over it.

    In WPF, this is pretty straightforward by using a Popup and VisualBrush. What the VisualBrush does is paint an area with a Visual Element - the container…

    • Sat, Jul 11 2009
  • XamDataGrid ColumnChooser Implementation

    This is a frequently asked scenario with the XamDataGrid. This is why I will be showing one way of how to enable a Column Chooser for your XamDataGrid.

    I have created a class ColumnChooserManager, which will create a small column chooser control and display it when you right click on the Field's Label. The ColumnChooser control is bound to a partucular XamDataGrid's FieldLayouts collection. It works with flat as well…

    • Sat, Jul 11 2009
  • Short Introduction & Bio

    Hello,

    I joined Infragistics in the beginning of February, 2009, working in the Developer Support Department. I am currently graduating from the Technical University of Sofia, Bulgaria. I like Coca-Cola, the beach and more coca-cola. Short, right.

    In my blog posts unfortunately, I will not invent the wheel. I will be showing new functionalities and cool things you can do as well as FAQs with the Infragistics WPF Controls…

    • Fri, Jul 10 2009