logo
  • 教程列表
  • SO官方文档
  • WebView 导航
    • 从应用包中打开 HTML 文件
    • 导航到 Uri
    • 使用 HttpRequestMessage 导航
    • 导航到字符串
    • 从 app 本地文件夹或临时文件夹打开 HTML 文件
    • NavigateToLocalStreamUri
  1. StackOverflow 文档
  2. uwp 教程
  3. WebView 导航
  4. 导航到字符串

导航到字符串

Created: November-22, 2018

在 WebView 中显示指定的 html 字符串:

var htmlString = 
    @"<!DOCTYPE html>
      <html>
          <head><title>HTML document</title></head>
          <body>
              <p>This is simple HTML content.</p>
          </body>
      </html>";

this.webView.NavigateToString(htmlString);
  • 从 app 本地文件夹或临时文件夹打开 HTML 文件
  • 使用 HttpRequestMessage 导航

Copyright © 2018. All right reserved

tastones.com 备案号:鲁ICP备18045372号-1

  • 关于我们
  • 免责声明