Using:
(App)App.Current
You can also create this property in your App class, so you do not need to do it every time:
public static new App Current { get { return Application.Current as App; } }
With this property, you can only link to your application using App.Current
Hope this helps!
alf
source share