正在加载图片...
②编写事件代码。编写 Page_ load的事件过程代码如下: protected void Page_ load(object sender, EventArgs e) TextBox My TextBox = new TextBoxO MyTextBox.Text="动态生成的文本框" Placeholder Controls. Add(MyTextBox Button MyButton= new Button MyButton Text="动态生成的按钮" Placehlolder1. Controls. Add ( My Button)◼ ② 编写事件代码。编写Page_Load的事件过程代码如下: ◼ protected void Page_Load(object sender, EventArgs e) ◼ { ◼ TextBox MyTextBox = new TextBox(); ◼ MyTextBox.Text = "动态生成的文本框"; ◼ PlaceHolder1.Controls.Add(MyTextBox); ◼ Button MyButton = new Button(); ◼ MyButton.Text = "动态生成的按钮"; ◼ PlaceHolder1.Controls.Add(MyButton); ◼ }
<<向上翻页向下翻页>>
©2008-现在 cucdc.com 高等教育资讯网 版权所有