一开始我已经加入了Microsoft.VisualBasic
命名空间
private void btnAddHousehold_Click(object sender, EventArgs e)
{
string Address = Interaction.InputBox("Enter the Address of the new Household","Add new Household");
if (Address != "")
{
Household temp = new Household();
temp.Address = Address;
Program.Households.Add(temp);
SaveToFile();
RefreshForm();
}
}
我希望弹出一个文本框并询问住户地址