In a Windows Phone 8 App, we sometimes need to call a method in MainPage.xaml.cs from a different class (App.xaml.cs for instance). And we might not be able to make it a static method.
There is a simple way to achieve this. Just create a static instance of the MainPage class in the class itself. Check the code below.
After this, you can simply call a method using…