Oct. 12, 2021, 12:10 p.m.
IT

Millennial Code - Real Production Code

This is how I'd expect a modern millennial to code (you know - the kind of person who considers facts to be particular opinions).

private bool CheckExist(out int id, out bool manageAll, out string orgCode)
{
        bool Yes = false; 
        id = -1;
        foreach (DataRow r in dv.Table.Rows)
        {
            if (r.ItemArray[1].ToString() == TextBoxUsername.Text && 
                r.ItemArray[2].ToString() == TextBoxPassword.Text)
            {
                Yes = true;
                id = (int) r.ItemArray[0];
                break;
            }
        }

    return Yes;
}