91av视频/亚洲h视频/操亚洲美女/外国一级黄色毛片 - 国产三级三级三级三级

資源簡介

WCF接收Client端數(shù)據(jù),進行轉(zhuǎn)發(fā)其他客戶端,也可以直接進行一對一通信,親測可用。

資源截圖

代碼片段和文件信息

using?System;
using?System.Collections.Generic;
using?System.Configuration;
using?System.Linq;
using?System.Text;
using?System.Threading.Tasks;

namespace?Client
{
????public?class?AppConfig
????{
????????public?string?UserName?{?get;?set;?}

????????public?string?GetUserName()
????????{
????????????return?“游客“?+?DateTime.Now.ToString(“MMddhhmmssfff“);
????????}
????????public?string?GetUserAppName()
????????{
????????????System.xml.xmlDocument?xDoc?=?new?System.xml.xmlDocument();
????????????xDoc.Load(System.Windows.Forms.Application.ExecutablePath?+?“.config“);

????????????System.xml.xmlNode?xNode;
????????????System.xml.xmlElement?xElem1;

????????????xNode?=?xDoc.SelectSingleNode(“//appSettings“);

????????????xElem1?=?(System.xml.xmlElement)xNode.SelectSingleNode(“//add[@key=‘UserName‘]“);
????????????return?xElem1.GetAttribute(“value“);
????????}
????????public?void?SetUserName(string?name)
????????{

????????????System.xml.xmlDocument?xDoc?=?new?System.xml.xmlDocument();
????????????xDoc.Load(System.Windows.Forms.Application.ExecutablePath?+?“.config“);

????????????System.xml.xmlNode?xNode;
????????????System.xml.xmlElement?xElem1;

????????????xNode?=?xDoc.SelectSingleNode(“//appSettings“);

????????????xElem1?=?(System.xml.xmlElement)xNode.SelectSingleNode(“//add[@key=‘UserName‘]“);
????????????if?(xElem1?!=?null)?xElem1.SetAttribute(“value“?name);

????????????xDoc.Save(System.Windows.Forms.Application.ExecutablePath?+?“.config“);

????????}
????}
}

評論

共有 條評論