c# - C#我无法在html文件中查看图片
问题描述
我的项目中有图像文件夹。我正在查看 html 文件,但无法查看图片。我不明白为什么我无法到达图片。
我的 HTML 代码
<p><img src="/images/aboutus_index.png" width="1020"/></p>
我的 c# 代码读取 html 文件。
Assembly assembly = Assembly.GetExecutingAssembly();
StreamReader reader = new StreamReader(assembly.GetManifestResourceStream("htmldeneme.index.html"));
webBrowser1.DocumentText = reader.ReadToEnd();
解决方案
推荐阅读
- python - tf.function 是否需要在内部函数中使用?
- java - 使用 Jackson 和 Map 处理时如何遍历 JSON 中的嵌套数据
- facebook - 发布后链接预览缩略图不正确
- flutter - 如何编写扩展方法来检查空白飞镖
- cassandra - cassandra 如何处理新节点(令牌如何重新分配)?
- c - CRC-16 的计算
- java - 如果超出连接数和线程数,Springboot Tomcat 快速失败
- html - HTML/CSS_IMG 和 SVG 分层
- postgresql - Eventuate Tram Saga 编排设计模式
- linux - 在 Jenkins 中无头运行期间面临错误:“WebDriverException:消息:未知错误:net::ERR_CONNECTION_TIMED_OUT”