I don't know the correct technical terms to describe my question, so I'll give an example:
private Point _PrivateVect = new Point();
public Point Publicvect
{
get
{
return _PrivateVect;
}
set
{
_PrivateVect = value;
}
}
The problem is that if I wanted to access Publicvect.X
I get the error Cannot modify the return value of 'Publicvect' because it is not a variable
. Is there a way around this? Or do I just need to do Publicvect = new Point(NewX, Publicvect.Y);
forever?