WinForm之DataBinding

private void Form2_Load(object sender, EventArgs e)
{
BB b = new BB();

button2.DataBindings.Add("Text", b, "s");
}

class BB
{
public string s { get; set; } = "66666";
}

posted @ 2020-01-07 16:46  水色天空  阅读(729)  评论(0编辑  收藏  举报