Inject a file in a xap using post-build event 

Let’s say that your application is dynamically loading resources, and you have to constantly add/remove new resources during the development. In this scenario, it could be a huge-time saver to just tell Visual Studio to take the contents of a folder and inject it into your application. I don’t think there’s an out-of-the-box way to […]

Cryptic error message in XAML 

Unexpected NONE in parse rule ElementBody ::= ATTRIBUTE* ( PropertyElement | Content )* . ENDTAG.. Best. Error message. Ever. Thanks Silverlight. So, what’s going on? For the sake of all the devs who’ll come to this page using Google, let’s describe one of the causes of the error message. Is that it? Yes, pretty much. […]

How to press the mouse on a control, and detect MouseLeftButtonUp on another 

Another issue I found on StackOverflow, which is way more tricky that it seems. Let’s say we have a Silverlight WP7 application, and we want to add a drag&drop scenario. The user first taps an element, drags his finger to another, and raises his finger on another element. Easy enough! Just handle the MouseLeftButtonDown on […]

ApplicationBar flickering when the phone theme is white 

It’s an interesting issue I found on StackOverflow. Interesting because I often forget to test my applications using the Windows Phone’s white theme, so this kind of problem usually goes unnoticed until a user reports it. Create a simple WP7 application with a black background and an ApplicationBar. Add a button to toggle the bar’s […]