资料.cs
上传用户:yan_wy
上传日期:2007-06-09
资源大小:112k
文件大小:7k
源码类别:

ICQ/即时通讯

开发平台:

C#

  1. using System;
  2. using System.Drawing;
  3. using System.Collections;
  4. using System.ComponentModel;
  5. using System.Windows.Forms;
  6. namespace qq
  7. {
  8. /// <summary>
  9. /// 资料 的摘要说明。
  10. /// </summary>
  11. public class 资料 : System.Windows.Forms.Form
  12. {
  13. UserControl1 control;
  14. private System.Windows.Forms.TextBox textBox1;
  15. private System.Windows.Forms.Label label1;
  16. private System.Windows.Forms.Label label2;
  17. private System.Windows.Forms.TextBox textBox2;
  18. private System.Windows.Forms.Label label3;
  19. private System.Windows.Forms.TextBox textBox3;
  20. private System.Windows.Forms.PictureBox pictureBox1;
  21. private System.Windows.Forms.Button button1;
  22. private System.Windows.Forms.Label label4;
  23. private System.Windows.Forms.RichTextBox richTextBox1;
  24. private System.Windows.Forms.Label label5;
  25. private System.Windows.Forms.TextBox textBox4;
  26. /// <summary>
  27. /// 必需的设计器变量。
  28. /// </summary>
  29. private System.ComponentModel.Container components = null;
  30. public 资料(UserControl1 aa)
  31. {
  32. //
  33. // Windows 窗体设计器支持所必需的
  34. //
  35. control=aa;
  36. InitializeComponent();
  37. this.textBox1.Text=control.uid;
  38. this.textBox2.Text=aa.name;
  39. this.textBox3.Text=aa.sex;
  40. this.textBox4.Text=aa.age;
  41. this.richTextBox1.Text=aa.jianjie;
  42.                  this.pictureBox1.Image=Image.FromFile(aa.form.path+@"newface"+(aa.picture).Trim()+".bmp");
  43. /* this.pictureBox1.Image= Image.FromFile
  44. (System.Environment.GetFolderPath
  45. (System.Environment.SpecialFolder.Personal)
  46. + @".newface"+(aa.picture).Trim()+".bmp");*/
  47. //
  48. // TODO: 在 InitializeComponent 调用后添加任何构造函数代码
  49. //
  50. }
  51. /// <summary>
  52. /// 清理所有正在使用的资源。
  53. /// </summary>
  54. protected override void Dispose( bool disposing )
  55. {
  56. if( disposing )
  57. {
  58. if(components != null)
  59. {
  60. components.Dispose();
  61. }
  62. }
  63. base.Dispose( disposing );
  64. }
  65. #region Windows 窗体设计器生成的代码
  66. /// <summary>
  67. /// 设计器支持所需的方法 - 不要使用代码编辑器修改
  68. /// 此方法的内容。
  69. /// </summary>
  70. private void InitializeComponent()
  71. {
  72. this.textBox1 = new System.Windows.Forms.TextBox();
  73. this.label1 = new System.Windows.Forms.Label();
  74. this.label2 = new System.Windows.Forms.Label();
  75. this.textBox2 = new System.Windows.Forms.TextBox();
  76. this.label3 = new System.Windows.Forms.Label();
  77. this.textBox3 = new System.Windows.Forms.TextBox();
  78. this.pictureBox1 = new System.Windows.Forms.PictureBox();
  79. this.button1 = new System.Windows.Forms.Button();
  80. this.label4 = new System.Windows.Forms.Label();
  81. this.richTextBox1 = new System.Windows.Forms.RichTextBox();
  82. this.label5 = new System.Windows.Forms.Label();
  83. this.textBox4 = new System.Windows.Forms.TextBox();
  84. this.SuspendLayout();
  85. // 
  86. // textBox1
  87. // 
  88. this.textBox1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
  89. this.textBox1.Location = new System.Drawing.Point(64, 32);
  90. this.textBox1.Name = "textBox1";
  91. this.textBox1.Size = new System.Drawing.Size(64, 21);
  92. this.textBox1.TabIndex = 0;
  93. this.textBox1.Text = "";
  94. // 
  95. // label1
  96. // 
  97. this.label1.Location = new System.Drawing.Point(16, 32);
  98. this.label1.Name = "label1";
  99. this.label1.Size = new System.Drawing.Size(40, 24);
  100. this.label1.TabIndex = 1;
  101. this.label1.Text = "QQ";
  102. // 
  103. // label2
  104. // 
  105. this.label2.Location = new System.Drawing.Point(8, 80);
  106. this.label2.Name = "label2";
  107. this.label2.Size = new System.Drawing.Size(48, 23);
  108. this.label2.TabIndex = 2;
  109. this.label2.Text = "呢称";
  110. // 
  111. // textBox2
  112. // 
  113. this.textBox2.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
  114. this.textBox2.Location = new System.Drawing.Point(64, 80);
  115. this.textBox2.Name = "textBox2";
  116. this.textBox2.Size = new System.Drawing.Size(64, 21);
  117. this.textBox2.TabIndex = 3;
  118. this.textBox2.Text = "";
  119. // 
  120. // label3
  121. // 
  122. this.label3.Location = new System.Drawing.Point(0, 128);
  123. this.label3.Name = "label3";
  124. this.label3.Size = new System.Drawing.Size(48, 24);
  125. this.label3.TabIndex = 4;
  126. this.label3.Text = "性别";
  127. this.label3.TextAlign = System.Drawing.ContentAlignment.TopCenter;
  128. // 
  129. // textBox3
  130. // 
  131. this.textBox3.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
  132. this.textBox3.Location = new System.Drawing.Point(64, 128);
  133. this.textBox3.Name = "textBox3";
  134. this.textBox3.Size = new System.Drawing.Size(64, 21);
  135. this.textBox3.TabIndex = 5;
  136. this.textBox3.Text = "";
  137. // 
  138. // pictureBox1
  139. // 
  140. this.pictureBox1.Location = new System.Drawing.Point(176, 32);
  141. this.pictureBox1.Name = "pictureBox1";
  142. this.pictureBox1.Size = new System.Drawing.Size(64, 48);
  143. this.pictureBox1.TabIndex = 6;
  144. this.pictureBox1.TabStop = false;
  145. // 
  146. // button1
  147. // 
  148. this.button1.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
  149. this.button1.Location = new System.Drawing.Point(168, 192);
  150. this.button1.Name = "button1";
  151. this.button1.Size = new System.Drawing.Size(72, 32);
  152. this.button1.TabIndex = 7;
  153. this.button1.Text = "关闭";
  154. this.button1.Click += new System.EventHandler(this.button1_Click);
  155. // 
  156. // label4
  157. // 
  158. this.label4.Location = new System.Drawing.Point(8, 192);
  159. this.label4.Name = "label4";
  160. this.label4.Size = new System.Drawing.Size(40, 24);
  161. this.label4.TabIndex = 8;
  162. this.label4.Text = "简介";
  163. // 
  164. // richTextBox1
  165. // 
  166. this.richTextBox1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
  167. this.richTextBox1.Location = new System.Drawing.Point(64, 176);
  168. this.richTextBox1.Name = "richTextBox1";
  169. this.richTextBox1.Size = new System.Drawing.Size(64, 56);
  170. this.richTextBox1.TabIndex = 9;
  171. this.richTextBox1.Text = "";
  172. // 
  173. // label5
  174. // 
  175. this.label5.Location = new System.Drawing.Point(152, 128);
  176. this.label5.Name = "label5";
  177. this.label5.Size = new System.Drawing.Size(32, 16);
  178. this.label5.TabIndex = 10;
  179. this.label5.Text = "年龄";
  180. // 
  181. // textBox4
  182. // 
  183. this.textBox4.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
  184. this.textBox4.Location = new System.Drawing.Point(208, 128);
  185. this.textBox4.Name = "textBox4";
  186. this.textBox4.Size = new System.Drawing.Size(56, 21);
  187. this.textBox4.TabIndex = 11;
  188. this.textBox4.Text = "";
  189. // 
  190. // 资料
  191. // 
  192. this.AutoScaleBaseSize = new System.Drawing.Size(6, 14);
  193. this.ClientSize = new System.Drawing.Size(292, 273);
  194. this.Controls.Add(this.textBox4);
  195. this.Controls.Add(this.label5);
  196. this.Controls.Add(this.richTextBox1);
  197. this.Controls.Add(this.label4);
  198. this.Controls.Add(this.button1);
  199. this.Controls.Add(this.pictureBox1);
  200. this.Controls.Add(this.textBox3);
  201. this.Controls.Add(this.label3);
  202. this.Controls.Add(this.textBox2);
  203. this.Controls.Add(this.label2);
  204. this.Controls.Add(this.label1);
  205. this.Controls.Add(this.textBox1);
  206. this.MaximizeBox = false;
  207. this.Name = "资料";
  208. this.Text = "资料";
  209. this.ResumeLayout(false);
  210. }
  211. #endregion
  212. private void button1_Click(object sender, System.EventArgs e)
  213. {
  214. this.Close();
  215. }
  216. }
  217. }