public TestGoogleURL(string gURL) { InitializeComponent(); txtUrl.Text = gURL; SurpressJavascriptErrors(); TripBrowser.Navigate(gURL); }
public MainWindow() { InitializeComponent(); //Get List of Chapters from Db chList = Helper.GoogleHelper.GetChapters(); dgChapters.ItemsSource = chList; TripBrowser.Navigate(uriGoogle); txtUrl.Text = uriGoogle; }
private void dgChapters_SelectionChanged(object sender, SelectionChangedEventArgs e) { DataGrid dg = sender as DataGrid; Model.ChapterMiles mile = (Model.ChapterMiles)dg.SelectedItem; //MessageBox.Show(ch.ChapterName.ToString()); SurpressJavascriptErrors(); TripBrowser.Navigate(mile.GoogleUri.ToString()); txtUrl.Text = mile.GoogleUri.ToString(); }
private void dgChapters_SelectionChanged(object sender, SelectionChangedEventArgs e) { DataGrid dg = sender as DataGrid; DAL.Chapter ch = (DAL.Chapter)dg.SelectedItem; //MessageBox.Show(ch.ChapterName.ToString()); SurpressJavascriptErrors(); string googleLink = null; googleLink = ch.GoogleLink; if (!string.IsNullOrEmpty(googleLink)) { TripBrowser.Navigate(googleLink); } txtUrl.Text = googleLink; }
private void txtUrl_KeyUp(object sender, KeyEventArgs e) { string uriCheck = txtUrl.Text; if (e.Key == Key.Enter) { if (uriCheck.Contains("http://") == false) { uriCheck = string.Concat("http://", uriCheck); } } if (uriCheck.Contains(".com") == false) { uriCheck = string.Concat(uriCheck, ".com"); } if (Uri.IsWellFormedUriString(uriCheck, UriKind.Absolute)) { SurpressJavascriptErrors(); TripBrowser.Navigate(uriCheck); } }
private void GoToPage_Executed(object sender, ExecutedRoutedEventArgs e) { TripBrowser.Navigate("https://www.google.com/"); }