Search
 
SCRIPT & CODE EXAMPLE
 

CSHARP

windows forms iterate through all controls

private void LoopThroughControls(Control parent)
{
    foreach (Control c in parent.Controls)
    {
        if (c.GetType() == typeof(YourType)) {
            //Do stuff
        } else {
            LoopThroughControls(c);
        }
    }
}
Comment

PREVIOUS NEXT
Code Example
Csharp :: how to make a dragable object in unity2D 
Csharp :: c# start as adminstrator 
Csharp :: dyncmics 365 setstate request 
Csharp :: minheap c# 
Csharp :: how to usefor loop in c# 
Csharp :: unity keep rotating object 
Csharp :: vs code explorer font size 
Csharp :: c# random choice 
Csharp :: c# convert to snake case 
Csharp :: InvalidOperationException: Calling Scene Raisefrom assembly reloading callbacks are not supported. 
Csharp :: c# check valid datetime 
Csharp :: enable canvas unity 
Csharp :: override indexation C# 
Csharp :: unity camera follow 
Csharp :: c# add guid to array 
Csharp :: base64 string to byte array c# 
Csharp :: C# fix formatting 
Csharp :: unity animator current state name 
Csharp :: unity get selected gameobject 
Csharp :: c# request run as administrator 
Csharp :: get enum by index c# 
Csharp :: unity set list of strings 
Csharp :: c# tryparse int 
Csharp :: c# reading months as int 
Csharp :: c# int to hex 
Csharp :: how to encode and decode a string in c# 
Csharp :: c# postmessage mouse click 
Csharp :: Get Index position of an element in a list in c# 
Csharp :: c# list append 
Csharp :: c# how many lines in methods 
ADD CONTENT
Topic
Content
Source link
Name
5+7 =