Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CSHARP

c# if break

public void Method()
{
    do
    {
        if (something)
        {
            // some code
            if (something2)
            {
                break;
            }
            
            return;
        }
        break;
    }
    while( false );

    // The code I want to go if the second `if` is true
}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #break
ADD COMMENT
Topic
Name
7+3 =