private float fsalary =20000;
public float Salary
public float Salary
{
set { fsalary = 500102; }
}
Emp e=new Emp();
Console.WriteLine("The Emp salary is:{0}",e.Salary);
How to access set property?
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Iftikar HussainPosted Aug 2, 2013, 3:16 AM
You should try like this
e.Salary=500102;
Regards,
Iftikar
VijayPosted Aug 2, 2013, 3:31 AM
Iftikar HussainPosted Aug 2, 2013, 3:26 AM
Regards,
Iftikar
VijayPosted Aug 2, 2013, 3:21 AM