Example of Hyperlink control in windows store app Tutorial

How to Navigate from page to specific URL

 Add HyperlinkButton control with specified code , code is

<Grid Background="{ThemeResource ApplicationPageBackgroundThemeBrush}">

        <HyperlinkButton FontSize=" 30" Content="Google.com" NavigateUri=" http://www.google.com" Margin="272,218,0,475" Height="75" />

    </Grid>

This code add into MainPage.xaml file
Code generate the following output
windows store How to Navigate from page to specific URLwindows store How to Navigate from page to specific URL


How to Navigate from one page to another page in windows store app tutorial

Add click event handler with HyperLinkButton control look like

Grid Background="{ThemeResource ApplicationPageBackgroundThemeBrush}">

        <HyperlinkButton Click="HyperlinkButton_Click" FontSize=" 30" Content="Move to Next page"  Margin="272,218,0,475" Height="75" />

    </Grid>
Add Handler code in MainPage.xaml.cs file

  private void HyperlinkButton_Click(object sender, RoutedEventArgs e)
        {
            this.Frame.Navigate(typeof(secondpage));

        }
Code Generate the following output
How to Navigate from one page to another page in windows store app tutorial

How to Navigate from one page to another page in windows store app tutorial

Comments

Popular posts from this blog

difference between structure and union in C Language

Difference between Linear search and Binary Search in c language

Difference between static and dynamic websites