Wednesday, April 27, 2011

April 28, 2011 a Microsoft Community Contributor Award!


I am proud and happy that today I got an email from Microsoft saying that "I was being recognized with Microsoft Community Contributor Award!"

This award earned me access to more resources from Microsoft. And will empower more to people like me who like to share and contribute to the community. Sharing and contributing to WPF and ADO.NET Entity forum is also a great opportunity to learn.


This is a great encouragement to me to continue what has been started.
and I am proud to say that this is my first badge on this small blog. :-)

Thanks Microsoft for giving me this Microsoft Community Contributor Award.

I accepted it with both hands.



Sunday, April 24, 2011

How to make your xlmns pointing to URL

Quite a few WPF developer knows that we can customize on how XAML namespaces represents the actual assembly (.dll). I too sometimes forgot how to customize it that is why I blogged this out.

When we represent the assembly/namespaces (dll) in our XAML; we do specify like this
   
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"

When we have our own namespace or assembly of controls we declare something like the bottom so that we could use some controls.

xmlns:custom="clr-namespace:WpfCustomControlLibrary1;assembly=WpfCustomControlLibrary1"


Actually, we also do namespacing like that one on the top which represent the presentationcore.dll To do it, we can put XMLDefinition in our namespaces.
[assembly: XmlnsDefinition("http://www.gioVhan.com", "WpfCustomControlLibrary1")]
namespace WpfCustomControlLibrary1
{
.....
}

In this way, the "http://www.gioVhan.com" is the representation of our assembly thus we can type like.







This is a very cool feature in WPF. When designing your own assemblies, you can create something like this. It will represent a more and clear namespace rather than pointing to clr-...

I will check on VS2010/EF4.0 if this feature was changed.

Thanks.