Recent Posts

0
Comments

C# Code Snippets for properties raising PropertyChanged event by marianor

I decided to publish the snippets I use to implement properties that raise the PropertyChanged event. There are two code snippets, one generates a property raising the event, it is called by typing propnpc in the code editor, and generates the following...
Filed under:
0
Comments

MOQ 3.5 Beta released by marianor

MOQ 3.5 Beta was released, it includes a lot of fixes of the previous version. You can get the binaries here . If you are using Visual Studio 2010 you should download the version called: Moq 3.5 Beta Binaries and Help (with Castle Assemblies) .
Filed under:
3
Comments

How to get notifications in attached properties by marianor

Sometime we need to know when an attached property change its value for a specific FrameworkElement. For example consider the following: < Canvas > < Button x : Name ="move" Content ="Move" Canvas.Left ="10" Canvas...
Filed under:
2
Comments

How to force a binding to update by marianor

It is really very simple, all that we need is the FrameworkElement and the DependencyProperty that we need refresh. I did some extensions method to update the target or the source of the binding: public static class BindingExtensions {    ...
Filed under:
4
Comments

Publish a Clickonce deploy with assemblies not referenced in Visual Studio 2008 SP1 by marianor

Some time ago I wrote a post about this subject, but that post only apply to Visual Studio 2005. The targets used in that post where changed. Basically this post is an update to Visual Studio 2008 SP1. Note that this post does not apply to Visual Studio...
Filed under:
2
Comments

How to disable Copy and Paste for a control in WPF by marianor

By default all the TextBox ’s (an other controls) in WPF have a default ContextMenu that allows copy, paste and cut. You can disable this menu by setting this property as “{x:Null}”, but the keys associated with the menu options still work. In order to...
Filed under:
4
Comments

WPF Validation with Attributes and IDataErrorInfo interface in MVVM by marianor

WPF provides validation infrastructure for binding scenarios through IDataErrorInfo interface. Basically you have to implement the Item[columnName] property putting the validation logic for each property in your Model (or ModelView) requiring validation...
Filed under:
1
Comments

MOQ 3.1 released by marianor

Finally MOQ 3.1 was released, it includes a lot of fixes of the previous version (3.0). You can get the binaries here .
Filed under:
0
Comments

Using expression trees to get property getter and setters by marianor

There are times when you need get and set property values and you do not know the type of the properties. One option is use reflection through GetValue and SetValue from PropertyInfo class, but this wears to poor performance in our code. In order to do...
Filed under:
0
Comments

Moq 3.0 Final by marianor

Finally the new version of Moq is released, check the new improvements and fixes here . You can get the binaries from http://moq.me/get . Enjoy It !!!
Filed under:
More Posts Next page »