In my windows 8 version of my phonegap application I am trying to use an application bar to switch to certain pages. The following code will not form a valid URI to navigate to. If anyone has a work around or way to make this particular code work it would be appreciated.
private void ApplicationBarIconButton_Click(object sender, EventArgs e)
{
try
{
if (button.Text == "Logout")
{
IsolatedStorageSettings.ApplicationSettings.Remove("UserName");
IsolatedStorageSettings.ApplicationSettings.Remove("Password");
NavigationService.Navigate(new Uri("/www/index.html", UriKind.Absolute));
}
}
catch (Exception ex)
{
string esfjdlkfj; //placeholder
}
}
如果正在使用jQuery Mobile,则可以使用invoke进行调用
$.mobile.changePage("index.html", {transition : "none" });
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.