【发布时间】:2016-06-09 22:42:15
【问题描述】:
我在 WinForm 内的 WebBrowser 控件中加载了一个 html 本地文件。在html代码中,我在%variables%中定义了一些变量。
我的问题是如何将WinForm中的字符串/数据传输/引用到加载的html页面中定义的%viarables%,并刷新WebBrowser上显示的加载的html页面。
以下是加载本地 html 文件的代码。任何建议将不胜感激。
顺便说一下,它是一个WinForm应用程序,不是asp.Net。
string curDir = Directory.GetCurrentDirectory(); this.webBrowser1.Url = new Uri(String.Format("file:///{0}/{1}", curDir + "\\Forms", fileName));
【问题讨论】: