Access and disable ToolStripItems (ToolStripButtons, ToolStripMenuItems) using their names
问题 I would like to disable UI elements (Controls, Components etc.) which names are stored in a database. My code works for Controls, but I would like to access (to disable them) ToolStripItems such as ToolStripButtons, ToolStripMenuItems etc.. This is my current code: Dim df_command As New SqlCommand("select * from treftab where ref_data = 'INTERVENTION' and ref_code = '0'", sfacon) Dim df_reader As SqlDataReader = df_command.ExecuteReader If df_reader.HasRows Then While df_reader.Read Dim