Category Archives: WPF

  • Add row at top of Grid in WPF

    Posted on September 17, 2012 by in C#, Dotnet, WPF

    It is a shame that we cannot add a row to the top of Grid without explicitly pushing all the remaining rows down.  It would have been good if Microsoft provide us way of doing it without this additional plumbing work. Since they are busy Windows 8 launch, we have to do it ourselves. I […]

    Post Tagged with , ,
  • Add Rows to Grid Dynamically in WPF

    Posted on September 13, 2012 by in Dotnet, WPF

    A Grid can be used to design complicated user interfaces where we need to place multiple elements in a tabular for of rows and columns layout.  In this article, I am going to demonstrate an example which would explain how to add rows to grid dynamically. Example Overview: In this example, we fetch list of […]

    Post Tagged with , ,
  • Custom Commands & Bindings in WPF

    Posted on April 25, 2012 by in C#, Dotnet, WPF

    In my previous article “Commands in WPF”, I have discusses about built-in commands and their behavior in WPF. In this article, I am going to explain how to create our own custom commands and bind them to input or mouse gestures. Key Gestures & Mouse Gestures as Command Sources An InputGesture can be used as […]

    Post Tagged with ,
  • Commands in WPF

    Posted on April 25, 2012 by in C#, Dotnet, WPF

    WPF-routed commands give you a specific mechanism for hooking up UI controls such as toolbar buttons and menu items to handlers without introducing a lot of tight coupling and repetitive code into your application. The routed command model in WPF can be broken up into four main concepts: the command, the command source, the command […]

    Post Tagged with ,
  • Grouping GridView in WPF

    Posted on April 13, 2012 by in C#, Dotnet, WPF

    ListView is an ItemsControl. Its content properties are Items and ItemsSource. It supports two modes i.e. GridView & Custom View. In GridView mode we display item content into columns. Windows Presentation Foundation (WPF) provides a GridView view mode that partitions the ListView data item content into columns. The properties and methods on GridView and its […]

    Post Tagged with , ,
  • Sorting GridView in WPF & C#

    Posted on April 11, 2012 by in C#, Dotnet, WPF

    We use ListView control to display data items.  The presentation of the data items in a ListView is defined by its view mode, which is specified by the View property. Windows Presentation Foundation (WPF) provides a GridView view mode that partitions the ListView data item content into columns. The properties and methods on GridView and […]

    Post Tagged with , ,
  • Using GridView WPF & C#

    Posted on April 11, 2012 by in C#, Dotnet, WPF

    GridView class is used for displaying data items of a list view control in a series of columns. We define these columns as GridViewColumn UIElements in XAML.  We can apply formatting to gridview rows by specifying styles for ListViewItem. We can also add visual elements by applying templates to the gridview. Example: In this example, […]

    Post Tagged with , ,
  • How to do asynchronous processing using delegates in C# & WPF

    Posted on March 23, 2012 by in C#, Dotnet, WPF

    We all know what delegates are. I am not going to bore you with what. If you are really interested in finding out, you could read my other blog “Delegates in C#”. When we do process heavy tasks we don’t want the user to wait and he does not want to wait. All he would […]

    Post Tagged with ,