投稿が重複していますが、質問には回答がありません。私の質問は、新しいフォームがメインフォーム内に作成されているかどうかです
var editor = new Edit(itemList, itemListBox);
editor.Show();
編集するデータのタイプは次のとおりです。
Dictionary<int, Item>
アイテムは以下:
public class Item
{
public string @Url { get; set; }
public string Name { get; set; }
public double Price { get; set; }
public Item(string @url, string name, double price)
{
this.Url = url;
this.Name = name;
this.Price = price;
}
public override string ToString()
{
return this.Name;
}
}
メイン ウィンドウ フォームで ListBox を更新できるように、エディターを閉じたときにハンドラーを追加するにはどうすればよいですか。