akjoshi's Blog
Born with a black thinking hat
-
Outrageous Work Conditions for a Developer analyst
Recently came across a job opening sent to me by a HR person on LinkedIn; The service based company is a very big name in IT but the work conditions mentioned in the job description were extremely unusual -
-
Attached Behavior for auto scrolling containers while doing Drag & Drop
This is a very common problem in WPF, if you support Drag & Drop within your Items control or across the controls like ListView, TreeView etc. and your List contains hundreds of items then it’s very hard to drag an item at the bottom to the top. Various solutions are available on net for this -
-
Working on WPF application Memory Profiling
Today, I am going to start with the task of memory profiling the WPF application, on which I am working from past few months. I have successfully done this in past, fixing a lot of memory leaks and improving the performance of WPF applications; As in past, I am hopeful of fixing some very interesting bugs and improve the application performance.
-
WPF DataGrid Customization: Resizing Row/Column through DataGridCell gridlines
In this post I am going to share my experience on how I achieved the functionality to resize DataGrid row/column from any cell in that row (not just the row header). We needed this functionality as our user can hide the DataGrid headers and it is not possible to resize the rows/columns after that.
-
Importance of specifying AncestorType with x:Type in RelativeSourceBinding
I am really very happy right now, for the past 4 days me and my team were trying to solve a very trivial bug in our application and finally it got resolved by just adding x:Type in our RelativeSource bindings;Can you believe this, a production issue getting resolved just by this simple change, I couldn’t; so I tested this fix at least ten times to believe it
-
Getting rid of heavy Multivalue Converters : My Encounter with Win Form style WPF apps 2
I recently came across the situation where I had to refactor the WPF code written in Win Forms Style; Code was having a lot of MultiValueConverters used for building the DataContext / ItemSources for Controls/ ListVies/ DataGrids etc. Following is the example of one of the converters I am talking about:
-
Creating custom filters in Resharper To-do Explorer
We can create a custom filter in Resharper To-Do explorer to filter out all the to-do items created by a specific person or with a particular string literal. This is very useful in case you are working in a big team and have habit to add To-do comments. Here are the steps to create a new filter with a specific string -
-
Resolving harmless binding errors in WPF
While developing WPF applications, you will notice a lot of binding errors being displayed in output window; like this
-
Using Triggers in place of converters: My Encounter with WinForm style WPF apps 1
I am working on some refactoring kind of tasks and thought to share some of my findings with you all. In one of the application I am working, lot of converters were used for determining the value of a property based on various conditions (values of other properties); It’s not required to use these converters at all and these can easily be replaced with Triggers. I don’t have any statistics in favor of triggers at present but some problems I see in using converters are –
-
How to To Create Dynamic Submenu's in WPF
For creating dynamic sub-menus, <MenuItem.ItemContainerStyle> must be used instead of using <MenuItem.ItemTemtplae>; Try to avoid using ItemTemplate , specially a MenuItem should not be used inside an ItemTemplate as it creates two menu items for a sub-menu.