Windows Forms can be hosted inside a WPF application using WindowsFormHost. In this post I will show how easily you can use WindowsFormHost to host a windows Form content inside a WPF application.
We all know that StaticResource works mainly with Freezables in WPF. You cannot define a resource like a Button or a TextBox as StaticResource because the runtime will count it to be shared and creating the resource more than once from Resources will leave you an exception.
If you have worked with WPF 3.5 before, you know that declaring a normal image in your code will render your image quite fine. But If you do the same thing in .NET 4.0 or even you convert your existing application from previous version to .NET 4.0, all the images that were rendering quite Ok in your previous… Read More »
WPF has a facility to search the AncestorType for a control from a child control such that it will find the next parent control that matches the Ancestor Type defined. Silverlight implements this feature to enable you to search your ancestor from child control from your visual tree and bind the child property with it. Lets take a… Read More »
WPF comes with lots of fun and advantages. We can change the look and behavior of a control very easily which would have been very cumbersome when we are in normal winforms applications. WPF has few flexibilities like Superior Binding capabilities, Animation, Transformation, Virtualizations etc. Each of these made the framework richer in all respect. In WPF, ListBox… Read More »
With the introduction of MVVM pattern and WPF code structure, we have gradually mould ourselves to separate our presentation layer more with the actual Views. In doing so, we have implemented a lots of interfaces, some corresponds to the Command interfaces using ICommand interface which lets you define your object to handle an Button Click event handlers while… Read More »
If you are building a WPF application with lots of animation inside it, may be some of which runs forever, you must have been a problem of eating up your entire CPU or a mammoth portion of CPU while the program is running. The problem is because by default, the framerate for WPF application is set to 60… Read More »
Animation in WPF application has few major hurdles when it is not used in optimally. For public applications, you need to give more stress on performance of the UI. If you use animation for your application, you need to ensure that it goes smoothly. Certain abrupt change in animation may sometimes produce rusty animation for your application. Lets… Read More »