How do I clear navigation history in Silverlight/Windows Phone 7?

前端 未结 5 1430
無奈伤痛
無奈伤痛 2021-02-10 08:18

I\'m making a Windows Phone 7 app that has login/logout semantics (authenticating to a web app). When the user logs out I navigate back to the login screen and forget the sessio

5条回答
  •  醉梦人生
    2021-02-10 09:20

    This code works well (it needs to be in your page), haven't tried to get it past certification yet but the code does work:

     while (true)
     {
         if (this.RemoveBackEntry() == null)
         {
             break;
         }
      }
    

    This does seem to differ with the documentation, which says an exception will be raised when there is no more items so I have logged a bug on user voice for this, so it may change in future.

提交回复
热议问题