etoday title trim
This commit is contained in:
2
ConfigForm.Designer.cs
generated
2
ConfigForm.Designer.cs
generated
@@ -658,7 +658,7 @@
|
|||||||
this.label9.Name = "label9";
|
this.label9.Name = "label9";
|
||||||
this.label9.Size = new System.Drawing.Size(132, 12);
|
this.label9.Size = new System.Drawing.Size(132, 12);
|
||||||
this.label9.TabIndex = 20;
|
this.label9.TabIndex = 20;
|
||||||
this.label9.Text = "Version : 2018.12.04.13";
|
this.label9.Text = "Version : 2019.08.07.00";
|
||||||
//
|
//
|
||||||
// cbMockTrading
|
// cbMockTrading
|
||||||
//
|
//
|
||||||
|
|||||||
@@ -161,8 +161,8 @@ namespace NewsCrawler
|
|||||||
|
|
||||||
foreach (var item in lists)
|
foreach (var item in lists)
|
||||||
{
|
{
|
||||||
string strTitle = item.SelectSingleNode(".//a").InnerText;
|
string strTitle = item.SelectSingleNode(".//a").InnerText.Trim();
|
||||||
string strTime = item.SelectSingleNode(".//span[contains(@class, 'flash_press')]").InnerText;
|
string strTime = item.SelectSingleNode(".//span[contains(@class, 'flash_press')]").InnerText.Trim();
|
||||||
string strURL = item.SelectSingleNode(".//a").GetAttributeValue("href", "");
|
string strURL = item.SelectSingleNode(".//a").GetAttributeValue("href", "");
|
||||||
strURL="http://www.etoday.co.kr/news/section/newsview.php?idxno="+Regex.Replace(strURL, @"\D", "");
|
strURL="http://www.etoday.co.kr/news/section/newsview.php?idxno="+Regex.Replace(strURL, @"\D", "");
|
||||||
|
|
||||||
@@ -243,7 +243,7 @@ namespace NewsCrawler
|
|||||||
|
|
||||||
foreach(var item in lists)
|
foreach(var item in lists)
|
||||||
{
|
{
|
||||||
string strTitle = item.SelectSingleNode(".//title").InnerText;
|
string strTitle = item.SelectSingleNode(".//title").InnerText.Trim();
|
||||||
strTitle = strTitle.Substring(iCDATALen, strTitle.Length-iCDATALen-3);
|
strTitle = strTitle.Substring(iCDATALen, strTitle.Length-iCDATALen-3);
|
||||||
string strTime = item.ChildNodes["pubDate"].InnerText;
|
string strTime = item.ChildNodes["pubDate"].InnerText;
|
||||||
DateTime time = Convert.ToDateTime(strTime);
|
DateTime time = Convert.ToDateTime(strTime);
|
||||||
|
|||||||
Reference in New Issue
Block a user