Commit e899889cfa1fd8f75720924450f854674b744dab
1 parent
16433f72
更换按钮和点击进入浏览器bug
Showing
4 changed files
with
24 additions
and
11 deletions
FRControl/App.config
... | ... | @@ -50,13 +50,13 @@ |
50 | 50 | <value>Resources/close.png</value> |
51 | 51 | </setting> |
52 | 52 | <setting name="caseName" serializeAs="String"> |
53 | - <value>案件信息公开</value> | |
53 | + <value>官网</value> | |
54 | 54 | </setting> |
55 | 55 | <setting name="lawyerName" serializeAs="String"> |
56 | - <value>预约律师接访</value> | |
56 | + <value>案件信息公开</value> | |
57 | 57 | </setting> |
58 | 58 | <setting name="personName" serializeAs="String"> |
59 | - <value>预约人民监督员接访</value> | |
59 | + <value>律师阅卷</value> | |
60 | 60 | </setting> |
61 | 61 | </FRControl.Properties.Settings> |
62 | 62 | </userSettings> | ... | ... |
FRControl/Properties/Settings.Designer.cs
... | ... | @@ -184,7 +184,7 @@ namespace FRControl.Properties { |
184 | 184 | |
185 | 185 | [global::System.Configuration.UserScopedSettingAttribute()] |
186 | 186 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] |
187 | - [global::System.Configuration.DefaultSettingValueAttribute("案件信息公开")] | |
187 | + [global::System.Configuration.DefaultSettingValueAttribute("官网")] | |
188 | 188 | public string caseName { |
189 | 189 | get { |
190 | 190 | return ((string)(this["caseName"])); |
... | ... | @@ -196,7 +196,7 @@ namespace FRControl.Properties { |
196 | 196 | |
197 | 197 | [global::System.Configuration.UserScopedSettingAttribute()] |
198 | 198 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] |
199 | - [global::System.Configuration.DefaultSettingValueAttribute("预约律师接访")] | |
199 | + [global::System.Configuration.DefaultSettingValueAttribute("案件信息公开")] | |
200 | 200 | public string lawyerName { |
201 | 201 | get { |
202 | 202 | return ((string)(this["lawyerName"])); |
... | ... | @@ -208,7 +208,7 @@ namespace FRControl.Properties { |
208 | 208 | |
209 | 209 | [global::System.Configuration.UserScopedSettingAttribute()] |
210 | 210 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] |
211 | - [global::System.Configuration.DefaultSettingValueAttribute("预约人民监督员接访")] | |
211 | + [global::System.Configuration.DefaultSettingValueAttribute("律师阅卷")] | |
212 | 212 | public string personName { |
213 | 213 | get { |
214 | 214 | return ((string)(this["personName"])); | ... | ... |
FRControl/Properties/Settings.settings
... | ... | @@ -42,13 +42,13 @@ |
42 | 42 | <Value Profile="(Default)">Resources/close.png</Value> |
43 | 43 | </Setting> |
44 | 44 | <Setting Name="caseName" Type="System.String" Scope="User"> |
45 | - <Value Profile="(Default)">案件信息公开</Value> | |
45 | + <Value Profile="(Default)">官网</Value> | |
46 | 46 | </Setting> |
47 | 47 | <Setting Name="lawyerName" Type="System.String" Scope="User"> |
48 | - <Value Profile="(Default)">预约律师接访</Value> | |
48 | + <Value Profile="(Default)">案件信息公开</Value> | |
49 | 49 | </Setting> |
50 | 50 | <Setting Name="personName" Type="System.String" Scope="User"> |
51 | - <Value Profile="(Default)">预约人民监督员接访</Value> | |
51 | + <Value Profile="(Default)">律师阅卷</Value> | |
52 | 52 | </Setting> |
53 | 53 | </Settings> |
54 | 54 | </SettingsFile> |
55 | 55 | \ No newline at end of file | ... | ... |
FRControl/WebView.cs
... | ... | @@ -45,9 +45,22 @@ namespace FRControl |
45 | 45 | } |
46 | 46 | private void webBrowser1_DocumentCompleted_1(object sender, WebBrowserDocumentCompletedEventArgs e) |
47 | 47 | { |
48 | - | |
48 | + //System.IO.StreamReader sr = new System.IO.StreamReader(webBrowser1.DocumentStream, Encoding.GetEncoding("gb2312")); | |
49 | + //string html = sr.ReadToEnd();//获取源文件 | |
50 | + //sr.Close(); | |
51 | + ///*截取table 的html源文件*/ | |
52 | + //int start = html.IndexOf("<div class='indexnews clearfix'>"); | |
53 | + //int end = html.IndexOf("</div>", start) + 8; | |
54 | + //string tbhtm = html.Substring(start, end - start); | |
55 | + | |
56 | + //webBrowser1.DocumentText = tbhtm;//设置为table的html代码 | |
57 | + //将所有的链接的目标,指向本窗体 | |
58 | + foreach (HtmlElement htmlElement in webBrowser1.Document.Links) | |
59 | + { | |
60 | + htmlElement.SetAttribute("target", "_self"); | |
61 | + } | |
49 | 62 | this.webBrowser1.Document.Window.Error += new HtmlElementErrorEventHandler(Window_Error); |
50 | - //获取网页的最大size | |
63 | + //获取网页的最大size | |
51 | 64 | Size szba = new Size(webBrowser1.Document.Body.ScrollRectangle.Width, webBrowser1.Document.Body.ScrollRectangle.Height); |
52 | 65 | Size sz = webBrowser1.Size; |
53 | 66 | int xbili = (int)((float)sz.Width / (float)szba.Width * 100);//水平方向缩小比例 | ... | ... |