一个输入框,一个按钮,点击按钮显示 using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Text; using System.Windows.Forms; namespace WindowsFrom1 { public partial class Form1 : Form { public Form1() { InitializeComponent(); } private void button1_Click(object sender, EventArgs e) { string name = textBox1.Text; // this.Text = name + "打印"; //第一种显示 this.Text=string.Format("{0}",name);//第二种占位符显示 } } }