2014年11月13日 星期四
99乘法表格子
----------------------------------------------------------------------------------------------------------------
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
namespace WindowsFormsApplication2
{
public partial class Form1 : Form
{
System.Windows.Forms.Button button1;
System.Windows.Forms.Button[] buttons;
Button[,] button = new Button[9, 9];
public Form1()
{
InitializeComponent();
}
private void Form1_Load(object sender, EventArgs e)
{
for (int i = 0; i < 9; i++)
{
for (int j = 0; j < 9; j++)
{
button[i, j] = new Button();
button[i, j].Location = new Point(i * 20, j * 20);
this.Controls.Add(button[i, j]);
}
}
}
}
}
訂閱:
張貼留言 (Atom)
沒有留言:
張貼留言