private void Debuggerform_Load(object sender, EventArgs e) { propertyGrid1.SelectedObject = objuse; var blocktsitem = new BlockToolStripButton(); blocktsitem.BlockSelected += new EventHandler<BlockToolStripButton.BlockToolStripButtonBlockSelectedArgs>(blocktsitem_BlockSelected); toolStrip1.Items.Add(blocktsitem); }
void blocktsitem_BlockSelected(object sender, BlockToolStripButton.BlockToolStripButtonBlockSelectedArgs e) { propertyGrid1.SelectedObject = e.SelectedBlock; }