Is there a command to select all controls ? RRS feed

  • Question

  • User-775831949 posted

     Hi I have more than 100 controls (labels, textboxes, menu, Gridviews etc).

    I want onclick a button to turn all these controls to visible = true

    Now I need to code them one by one.

    Is there a code (in VB if possible) to make it applies to all in the control ?


    Wednesday, October 7, 2009 9:35 PM


  • User533502567 posted

     Can do some thing like this..

    For Each c As Control In Page.Controls
    c.Visible = false


    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Wednesday, October 7, 2009 9:45 PM

All replies