C# 模糊和不受阻碍的事件。错误

C# 模糊和不受阻碍的事件。错误,c#,windows-phone-8,windows-phone,C#,Windows Phone 8,Windows Phone,我试图写一个模糊的、不受阻碍的事件,但其中有一个错误: PhoneApplicationFrame phoneAppRootFrame = (Application.Current as App).RootFrame 错误: Auf den Member 'Timer.App.RootFrame.get' kann nicht mit einem Instanzenverweis zugegriffen werden. Qualifizieren Sie ihn stattdessen mit

我试图写一个模糊的、不受阻碍的事件,但其中有一个错误:

PhoneApplicationFrame phoneAppRootFrame = (Application.Current as App).RootFrame
错误:

Auf den Member 'Timer.App.RootFrame.get' kann nicht mit einem Instanzenverweis zugegriffen werden. Qualifizieren Sie ihn stattdessen mit einem Typnamen.
错误是德语的,因为我使用的是Visual Studio的德语版本

我怎样才能解决这个问题

编辑:

代码:

PhoneApplicationFrame phoneAppRootFrame = (Application.Current as App).RootFrame;
phoneAppRootFrame.Obscured += OnObscured;
phoneAppRootFrame.Unobscured += Unobscured;

请提供错误的英文版本,以使事情更简单。我使用google translate并得到“This member'Timer.App.RootFrame.get”无法通过实例引用访问。请使用类型名对其进行限定。“这与发布的代码不一致。”。你能提供更多的相关代码吗?好的,我发布了更多的代码(查看编辑:)尝试
PhoneApplicationFrame phoneAppRootFrame=(Application.Current as App)::RootFrame谢谢你的快速回答,但是当我尝试这个时,有两个错误1。Syntaxfehler。“.”Erwarett.2.与以前相同的错误您在哪里进行这些更改?在App.xaml.cs中?如果是这样的话,你应该说
RootFrame.obclused+=OnObscured等等。如果它在另一个类中,我不知道为什么你的初始方法会失败。你确定错误确实在你认为的线路上吗?