I have a simple window :
That's because the data context of your view hasn't been set. You could either do this in the code behind:
this.DataContext = this;
Alternatively, you could set the Window's DataContext
to itself - DataContext="{Binding RelativeSource={RelativeSource Self}}"
You're much better off though investigating the MVVM design pattern, and using an MVVM framework.