HTML WebView control sample

This sample demonstrates how to use WebView.

3.7 Star
5,228 times
Add to favorites
E-mail Twitter Digg Facebook
Copyright (c) Microsoft Corporation. All rights reserved

<!DOCTYPE html>
<html xmlns="">
    <title>Scenario 2: Navigate to a string</title>
    <link rel="stylesheet" href="/css/2_NavToString.css" />
    <script src="/js/2_NavToString.js"></script>
    <div data-win-control="SdkSample.ScenarioInput">
        <p>The WebView control can load an arbitrary string of HTML in addition to navigating to web pages. Click the "Load HTML" button to load the HTML in the text area into the WebView control with the navigateToString method. You can edit the text area to try loading different contents.</p>
        <button id="loadButton">Load HTML</button>
    <div data-win-control="SdkSample.ScenarioOutput" id="outputContainer">
        <div id="scenario2_left">
            <textarea id="htmlString"></textarea>
        <div id="scenario2_right">
            <x-ms-webview id="webview"></x-ms-webview>