Answers for "c# on variable change property get set"

C#
0

c# on variable change property get set

public int MyProperty
{
    get { return _myProperty; }
    set
    {
        _myProperty = value;
        if (_myProperty == 1)
        {
            // DO SOMETHING HERE
        }
    }
}

private int _myProperty;
Posted by: Guest on January-06-2022

C# Answers by Framework

Browse Popular Code Answers by Language