Form1.cs
上传用户:chinafred
上传日期:2007-08-14
资源大小:10127k
文件大小:5k
源码类别:

数据库编程

开发平台:

C#

  1. using System;
  2. using System.Drawing;
  3. using System.Collections;
  4. using System.ComponentModel;
  5. using System.Windows.Forms;
  6. using System.Data;
  7. namespace ch1_15
  8. {
  9. /// <summary>
  10. /// Form1 的摘要说明。
  11. /// </summary>
  12. public class Form1 : System.Windows.Forms.Form
  13. {
  14. private System.Windows.Forms.PictureBox pictureBox1;
  15. private System.Windows.Forms.Splitter splitter1;
  16. private System.Windows.Forms.RichTextBox richTextBox1;
  17. private System.Windows.Forms.Splitter splitter2;
  18. private System.Windows.Forms.ListView listView1;
  19. private System.Windows.Forms.ColumnHeader columnHeader1;
  20. private System.Windows.Forms.ColumnHeader columnHeader2;
  21. private System.Windows.Forms.ColumnHeader columnHeader3;
  22. /// <summary>
  23. /// 必需的设计器变量。
  24. /// </summary>
  25. private System.ComponentModel.Container components = null;
  26. public Form1()
  27. {
  28. //
  29. // Windows 窗体设计器支持所必需的
  30. //
  31. InitializeComponent();
  32. //
  33. // TODO: 在 InitializeComponent 调用后添加任何构造函数代码
  34. //
  35. }
  36. /// <summary>
  37. /// 清理所有正在使用的资源。
  38. /// </summary>
  39. protected override void Dispose( bool disposing )
  40. {
  41. if( disposing )
  42. {
  43. if (components != null) 
  44. {
  45. components.Dispose();
  46. }
  47. }
  48. base.Dispose( disposing );
  49. }
  50. #region Windows Form Designer generated code
  51. /// <summary>
  52. /// 设计器支持所需的方法 - 不要使用代码编辑器修改
  53. /// 此方法的内容。
  54. /// </summary>
  55. private void InitializeComponent()
  56. {
  57. System.Resources.ResourceManager resources = new System.Resources.ResourceManager(typeof(Form1));
  58. System.Windows.Forms.ListViewItem listViewItem1 = new System.Windows.Forms.ListViewItem(new string[] {
  59.  "皮耶罗",
  60.  "意大利",
  61.  "尤文图斯"}, -1, System.Drawing.SystemColors.WindowText, System.Drawing.SystemColors.Window, new System.Drawing.Font("宋体", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((System.Byte)(134))));
  62. this.pictureBox1 = new System.Windows.Forms.PictureBox();
  63. this.splitter1 = new System.Windows.Forms.Splitter();
  64. this.richTextBox1 = new System.Windows.Forms.RichTextBox();
  65. this.splitter2 = new System.Windows.Forms.Splitter();
  66. this.listView1 = new System.Windows.Forms.ListView();
  67. this.columnHeader1 = new System.Windows.Forms.ColumnHeader();
  68. this.columnHeader2 = new System.Windows.Forms.ColumnHeader();
  69. this.columnHeader3 = new System.Windows.Forms.ColumnHeader();
  70. this.SuspendLayout();
  71. // 
  72. // pictureBox1
  73. // 
  74. this.pictureBox1.Dock = System.Windows.Forms.DockStyle.Top;
  75. this.pictureBox1.Image = ((System.Drawing.Bitmap)(resources.GetObject("pictureBox1.Image")));
  76. this.pictureBox1.Name = "pictureBox1";
  77. this.pictureBox1.Size = new System.Drawing.Size(440, 160);
  78. this.pictureBox1.TabIndex = 0;
  79. this.pictureBox1.TabStop = false;
  80. // 
  81. // splitter1
  82. // 
  83. this.splitter1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
  84. this.splitter1.Dock = System.Windows.Forms.DockStyle.Top;
  85. this.splitter1.Location = new System.Drawing.Point(0, 160);
  86. this.splitter1.MinExtra = 0;
  87. this.splitter1.Name = "splitter1";
  88. this.splitter1.Size = new System.Drawing.Size(440, 3);
  89. this.splitter1.TabIndex = 1;
  90. this.splitter1.TabStop = false;
  91. // 
  92. // richTextBox1
  93. // 
  94. this.richTextBox1.Dock = System.Windows.Forms.DockStyle.Left;
  95. this.richTextBox1.Location = new System.Drawing.Point(0, 163);
  96. this.richTextBox1.Name = "richTextBox1";
  97. this.richTextBox1.Size = new System.Drawing.Size(100, 110);
  98. this.richTextBox1.TabIndex = 2;
  99. this.richTextBox1.Text = "Alex Del Piero";
  100. // 
  101. // splitter2
  102. // 
  103. this.splitter2.Location = new System.Drawing.Point(100, 163);
  104. this.splitter2.Name = "splitter2";
  105. this.splitter2.Size = new System.Drawing.Size(3, 110);
  106. this.splitter2.TabIndex = 3;
  107. this.splitter2.TabStop = false;
  108. // 
  109. // listView1
  110. // 
  111. this.listView1.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
  112. this.columnHeader1,
  113. this.columnHeader2,
  114. this.columnHeader3});
  115. this.listView1.Dock = System.Windows.Forms.DockStyle.Fill;
  116. this.listView1.Items.AddRange(new System.Windows.Forms.ListViewItem[] {
  117.   listViewItem1});
  118. this.listView1.Location = new System.Drawing.Point(103, 163);
  119. this.listView1.Name = "listView1";
  120. this.listView1.Size = new System.Drawing.Size(337, 110);
  121. this.listView1.TabIndex = 4;
  122. this.listView1.View = System.Windows.Forms.View.Details;
  123. // 
  124. // columnHeader1
  125. // 
  126. this.columnHeader1.Text = "球员";
  127. // 
  128. // columnHeader2
  129. // 
  130. this.columnHeader2.Text = "国籍";
  131. // 
  132. // columnHeader3
  133. // 
  134. this.columnHeader3.Text = "效力俱乐部";
  135. this.columnHeader3.Width = 126;
  136. // 
  137. // Form1
  138. // 
  139. this.AutoScaleBaseSize = new System.Drawing.Size(6, 14);
  140. this.ClientSize = new System.Drawing.Size(440, 273);
  141. this.Controls.AddRange(new System.Windows.Forms.Control[] {
  142.   this.listView1,
  143.   this.splitter2,
  144.   this.richTextBox1,
  145.   this.splitter1,
  146.   this.pictureBox1});
  147. this.Name = "Form1";
  148. this.Text = "分隔窗体";
  149. this.ResumeLayout(false);
  150. }
  151. #endregion
  152. /// <summary>
  153. /// 应用程序的主入口点。
  154. /// </summary>
  155. [STAThread]
  156. static void Main() 
  157. {
  158. Application.Run(new Form1());
  159. }
  160. }
  161. }