form1.cs
来自「清华大学出版社出版的 移动应用开发宝典 张大威(2008)的附书源代码」· CS 代码 · 共 34 行
CS
34 行
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
namespace Configuration
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private void Form1_Load(object sender, EventArgs e)
{
System.Xml.XmlDocument d = new System.Xml.XmlDocument();
d.LoadXml("<wap-provisioningdoc><characteristic type=\"CM_Mappings\"><characteristic type=\"16777217\"><parm name=\"Pattern\" value=\"*://myserver.com/*\" /><parm name=\"Network\" value=\"{A1182988-0D73-439E-87AD-2A5B369F808B}\" /></characteristic></characteristic></wap-provisioningdoc>");
System.Xml.XmlDocument d2 = Microsoft.WindowsMobile.Configuration.ConfigurationManager.ProcessConfiguration(d, true);
MessageBox.Show(d2.OuterXml);
}
private void btnGPRS_Click(object sender, EventArgs e)
{
System.Xml.XmlDocument d = new System.Xml.XmlDocument();
d.Load(System.Reflection.Assembly.GetExecutingAssembly().GetManifestResourceStream("Chapter17.Favorite.xml"));
System.Xml.XmlDocument d2 = Microsoft.WindowsMobile.Configuration.ConfigurationManager.ProcessConfiguration(d, true);
MessageBox.Show(d2.OuterXml);
}
}
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?