We want to control the appearance of a set or class of combo boxes or respond to some behavior by writing a combo box click event
Private Sub TextBox_ComName_Click(sender As Object, e As EventArgs) Handles ComboBox_AreaName.Click
sender.DroppedDown = True
End Sub
The reason for using the event's "sender" parameter instead of the control name is that we want to control multiple controls at the same time with just one event
Compiler Error CS1061:'type' does not contain a definition for 'name' and no accessible extension method 'name' accepting a first argument of type 'type' could be found (are you missing a using directive or an assembly reference?).
Expected output
will be referenced by multiple combo box click events
VB.Net input code
We want to control the appearance of a set or class of combo boxes or respond to some behavior by writing a combo box click event
The reason for using the event's "sender" parameter instead of the control name is that we want to control multiple controls at the same time with just one event
Erroneous output
Compiler Error CS1061:'type' does not contain a definition for 'name' and no accessible extension method 'name' accepting a first argument of type 'type' could be found (are you missing a using directive or an assembly reference?).
Expected output
will be referenced by multiple combo box click events
Details