Windows Store RT: Save game/application state when closing app via close gesture or Alt+F4

If you has already family with Windows Phone development. You may often saving application/game state by overriding MainPage's OnNavigatedFrom event. But with Windows Store app (Windows RT). The event is not fire when user is closing application by "close gesture" or Alt+F4 keyboard function. So the question is how to…

Continue ReadingWindows Store RT: Save game/application state when closing app via close gesture or Alt+F4

Applying DataTemplate programmatically in Windows 8 Store App

Sometime you want to apply dynamic layout and content for Windows Store app. For example, when user click on button or changing the windows orientation. In that case, you could use animation and StoryBoard. But sometime you could not and need to implement by code. In this article I will…

Continue ReadingApplying DataTemplate programmatically in Windows 8 Store App

How to check for memory leaks in WP7 pages

In your App.xaml.cs, in your CompleteInitializePhoneApplication method add: Add this code to each page and if you do not recieve a messagebox when going back then you may have a memory leak. Sometimes you have to navigate to other pages to recieve a messagebox. Known Memory Leaks1. I discovered that…

Continue ReadingHow to check for memory leaks in WP7 pages