C # Are you missing a usage directive or assembly reference?

This error message appeared during compilation after I removed all the code for the behavior of the tabPage1_Click event.

It had no body code, because I accidentally clicked on it quickly twice, and the event code was added to the source when I just started programming the application. Now I'm done, and all the tops are tops, except that the useless definition is tabPage1_Click.

Error 1 "Bar.placeOrderForm" does not contain a definition for "tabPage1_Click", and the extension method "tabPage1_Click" cannot be found that takes the first argument of the type "Bar.placeOrderForm" (do you miss the use directive or build link?) C: \ admin \ Bar \ Bar \ placeOrderForm.Designer.cs 96 67 Bar

+3
source share
5 answers

Go to the constructor for your placeOrderForm form, select tabPage1 from the list of fields in the Properties window, select the Events view, and simply clear the entry (read tabPage1_Click) in the Click event.

Must see you right.

+3
source

Removed highlighted line in .designer.cs file

enter image description here

+3
source

, , - : ...+=tabPage1_Click(...) , , .

0

, , , , , , , , .

What you want to do is select tabPage1 in the designer, then go to the "Properties" window and click on the zipper to switch to viewing events. Then scroll down to Clickand release this field.

0
source

To solve, check the dll and the pdb file urapapication or as an update loading the bin folder

0
source

Source: https://habr.com/ru/post/1790814/


All Articles