c#ÖÐÒ»¸ö´°Ìåµ÷ÓÃÁíÒ»¸ö´°ÌåµÄ¿Ø¼þ¼°·½·¨£¨×ªÌù£©
²Î¿¼×ÊÁÏ£ºhttp://wenwen.soso.com/z/q39607884.htm
ÈçºÎÔÚÒ»¸ö´°ÌåÖе÷ÓÃÁíÒ»¸ö´°ÌåµÄ¿Ø¼þ»ò·½·¨
´ð°¸ÊÇ´Ó¹¹Ô캯ÊýÖд«µÝ²ÎÊý¡£
Òª°ÑForm1ÖеĿؼä¸Ä³ÉpublicÊôÐÔ
¾ßÌåʵÏÖ¹ý³ÌÇë²Î¿´Ò»Ï´úÂë(ÔÚform2µÄtextbox1ÖÐÊäÈëÈ»ºóÔÚform1ÖеÄlabel1ÖÐÏÔʾtextboxÖеÄÄÚÈÝ
//form1´úÂë,form1ÖÐÓÐÒ»¸ölabel1ºÍÒ»¸öbutton1,ÆäÖÐlabel1µÄmodifierÊôÐÔΪpublic
namespace WindowsApplication1
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private void button1_Click(object sender, EventArgs e)
{
//ÏÔʾform2
Form2 f2 = new Form2(this);
f2.Show();
}
}
}
//form2´úÂë,ÓÐÒ»¸ötextbox1,ÓÃÓÚÊäÈë,ÓÐÒ»¸öbutton1
namespace WindowsApplication1
{
public partial class Form2 : Form
{
public Form2(Form1 parent)
{
InitializeComponent();
paf = parent;
}
private Form1 paf;
private void button1_Click(object sender, EventArgs e)
{
paf.label1.Text = textBox1.Text;
this.Hide();
}
}
}
Ïà¹ØÎĵµ£º
ºÅ³ÆxmlhelperµÄÒ»¸öÀà
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Xml;
namespace WebApplication2
{
/// <summary>
/// XMLHelper XMLÎĵµ²Ù×÷¹ÜÀíÆ÷
/// </summary>
public class XMLHelper
{
public X ......
XmlDocument doc = new XmlDocument();
XmlDeclaration dec = doc.CreateXmlDeclaration("1.0", "GB2312", null);
doc.AppendChild(dec);
//´´½¨Ò»¸ö¸ù½Úµã£¨Ò»¼¶£©
XmlElement root = doc.CreateElement("First");
doc.AppendChild(root);
//´´½¨½Úµã£ ......
public sealed class DbOper
{
///<summary>
/// DbOperÀàµÄ¹¹Ô캯Êý
///</summary>
private DbOper()
{
}
......
private void MakeLegend(IActiveView activeView,IPageLayout pageLayout)
{
//¶¨ÒåͼÀýUID¶ÔÏó
UID uid = new UIDClass();
&n ......
Ô´ÂëÈçÏ£º
using System;
using System.Collections;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using System.Diagnostics;
using System.Runtime.InteropServices;
using System.IO;
using Microsoft.Win32;
namespace mv
{
......