界面如图:
一个开始button;停止button;picture控件;timer控件
代码:
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace 课题二转换区仿真
{
public partial class Form1 : Form
{
Boolean b = true;
private int startY = 0;
public Form1()
{
InitializeComponent();
this.StartPosition = FormStartPosition.CenterScreen;
}
private void timer1_Tick(object sender, EventArgs e)
{
int i = pictureBox1.Location.X + 10;//图片