close

9X9乘法表_1  

=====================================================================

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 WindowsFormsApplication1
{

public partial class Form1 : Form
{
//System.Windows.Forms.Button Button1;
//System.Windows.Forms.Button[][] Buttons;
Button[,] buttons = 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++)
{
buttons[i, j] = new Button();
buttons[i, j].Location = new Point(i * 50, j * 50);
buttons[i, j].Size = new Size(50, 50);
this.Controls.Add(buttons[i, j]);
buttons[i, j] =

Console.WriteLine();
}

}

}

//Button1 = new System.Windows.Forms.Button();
//Button1.Location = new Point(100, 100);
//Button1.Click += new EventHandler(Button1_Click);
//this.Controls.Add(Button1);
//Buttons[i].Click += new System.EventHandler(this.Button_Click);
//Button[] butArray = new Button[3];
}

 

}

 

arrow
arrow
    全站熱搜

    鄭莠蓉 發表在 痞客邦 留言(0) 人氣()