線形圖
站在用戶的角度思考問題,與客戶深入溝通,找到尼瀘西網(wǎng)站設(shè)計(jì)與尼瀘西網(wǎng)站推廣的解決方案,憑借多年的經(jīng)驗(yàn),讓設(shè)計(jì)與互聯(lián)網(wǎng)技術(shù)結(jié)合,創(chuàng)造個(gè)性化、用戶體驗(yàn)好的作品,建站類型包括:成都網(wǎng)站設(shè)計(jì)、成都網(wǎng)站制作、企業(yè)官網(wǎng)、英文網(wǎng)站、手機(jī)端網(wǎng)站、網(wǎng)站推廣、主機(jī)域名、雅安服務(wù)器托管、企業(yè)郵箱。業(yè)務(wù)覆蓋尼瀘西地區(qū)。
前臺代碼:
<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Line.aspx.cs" Inherits="hhh.Line" %>
后臺代碼:
public string str = "";//文本
public string strdata = "";//數(shù)據(jù)
public double allcount = 0;
protected void Page_Load(object sender, EventArgs e)
{
LoadData();
}
protected void LoadData()
{
XmlDocument myDoc = new XmlDocument();
myDoc.Load(Server.MapPath("DB_51aspx.xml"));
XmlNode xn = myDoc.SelectSingleNode("http://VoteInfo[ID='2']");//讀取數(shù)據(jù)源
XmlNodeList xnl = xn.SelectNodes("Item");
double AllCount = 0;//總數(shù)
for (int i = 0; i < xnl.Count; i++)
{
AllCount += Convert.ToSingle(xnl.Item(i).SelectSingleNode("Count").InnerText);
}
allcount = AllCount;
for (int i = 0; i < xnl.Count; i++)
{
XmlNode xn0 = xnl.Item(i);
strdata += xn0.SelectSingleNode("Count").InnerText+ ",";
str += "\'" + xn0.SelectSingleNode("Title").InnerText + "\'" + ",";
}
strdata = strdata.Remove(strdata.Length-1,1);
str = str.Remove(str.Length-1,1);
}
效果圖展示: