Skip to content

{ Tag Archives } .NET

WinRT XAML Validation library: UI Controls for Validation

After you’ve defined the validation logic for your entities and performed validation automatically or manually, you want to show the aggregated validation messages on the UI. Unfortunately WinRT/XAML doesn’t come with such a functionality out of the box and solutions like Prism for Windows Runtime don’t add much value here as well. WinRT XAML Validation […]

Also tagged , , , ,

WinRT XAML Validation library: Manual Validation

Defining validation logic using Data Annotations is the default and recommended way in the WinRT XAML Validation library. But of course there are good reasons that you don’t want to use this approach. For example, you want to have all the validation logic for an entity at a central place or you don’t want your […]

Also tagged , , , ,

WinRT XAML Validation library: Implicit and Explicit Validation Execution

Now that you have defined all your validation attributes on your model classes, you want to perform validation to detect if your entity is valid or not. Here you can go two ways with the WinRT XAML Validation library: implicit validation validates your entity automatically when properties change, while with explicit validation you call a function […]

Also tagged , , , ,

WinRT XAML Validation library: Async Validation Attributes

Last posts have shown how basic validation attributes and property-group based validation attributes can be used to define custom validation logic, that goes beyond the default capabilities of Data Annotations. There’s another validation attribute base class in the WinRT XAML Validation library and that’s the AsyncValidationAttribute and its sister, the AsyncGroupValidationAttribute. Both attributes define the […]

Also tagged , , , ,

WinRT XAML Validation library: Property-Group Validation Attributes

All predefined validation attributes in the System.ComponentModel.DataAnnotations namespace can be used to annotate a single property of an entity. So they cannot be used for validation that spans multiple properties. For this case, the WinRT XAML Validation library comes with the GroupValidationAttribute base class. Its member CausativeProperties can be used to define properties, which cause […]

Also tagged , , , ,

WinRT XAML Validation library: Basic Validation Attributes

Validation in the WinRT XAML Validation library is mainly based on .NET Data Annotations from the System.ComponentModel.DataAnnotations namespace. Here you can find several attributes, that you can attach to your entities and its properties. This annotates them with additional information/metadata, which’s evaluated elsewhere in your code or by the .NET framework. WPF, Silverlight and e.g. […]

Also tagged , , , ,

WinRT XAML Validation library: Getting Started

This little blog posts describes how you can include the WinRT XAML Validation library in your project and get it to work. Download First go to the WinRT XAML Validation Codeplex project page and download the latest bits. The download package includes the sources of the library as well as a demo project (Windows Store […]

Also tagged , , , ,

Introducing the WinRT XAML Validation library

In this article I’m going to introduce “WinRT XAML Validation”, a library that brings consistent validation of user input to WinRT/C#/XAML apps. Upcoming blog posts will cover several aspects of the library in depth. Prologue I like WinRT. I like its approach of bringing common functionality to very different languages. But WinRT is not perfect. At least […]

Also tagged , , , ,

C# 4.0 Neuerungen

Die ersten Neuerungen kurz in 3 Stichpunkten: Aufruf dynamischer Sprachen: dynamic-Schlüsselwort Optionale Funktionsparameter wie in C++ (wie ich das vermisst habe!) Rückgabe anonymer Typen durch Funktionen Einen umfassenden Überblick über die Neuerungen gibt ein Word-Dokument, welches Microsoft hier zum Download bereitstellt. Links: http://www.outofcoffeeexception.de/2008/10/27/C+40+Dynamic+Keyword.aspx http://www.outofcoffeeexception.de/2008/10/27/C+40+Optionale+Parameter.aspx http://www.outofcoffeeexception.de/2008/10/27/C+40+Mit+Dynamic+Anonyme+Typen+Zuruumlckgeben+Und+Verwenden.aspx http://blogs.msdn.com/dparys/archive/2008/10/28/neue-m-glichkeiten-in-c-4-0.aspx

Also tagged ,

Ein Blick auf F#

Funktionale Programmierung hat mich bereits während des Studiums beschäftigt, allerdings eher am Rande in Lehrveranstaltungen wie “Objektorientierte Konzepte”, wo in den Übungen Haskell gepredigt wurde. Teils verwirrt, teils fasziniert von dieser Art zu denken und zu programmieren hat mich das Thema nie richtig losgelassen und erlebt gerade einen persönlichen Aufschwung durch F#. F# ist Microsoft’s […]

Also tagged , , , ,