private void ReadMutualXML()
{
string strFilePath = Application.StartupPath + "\\" + "MutualConfig.xml";
XmlDocument xmlDoc = new XmlDocument();
xmlDoc.Load(strFilePath);
XmlNode xn = xmlDoc.SelectSingleNode("Mutual");
foreach (XmlNode cxn in xn.ChildNodes)
{
if (cxn.Name.Equals("IP"))
{
m_proxyIP = cxn.InnerText;
}
else if (cxn.Name.Equals("Port"))
{
m_proxyPort = Convert.ToInt32(cxn.InnerText);
}
else if (cxn.Name.Equals("UserName"))
{
m_username = cxn.InnerText;
}
else if (cxn.Name.Equals("Password"))
{
m_password = cxn.InnerText;
}
}
}
posted on 2008-11-12 16:35
天書 閱讀(149)
評(píng)論(0) 編輯 收藏 引用