Convert from string to system.drawing.point c#
I want to convert from string {X=-24,Y=10} which generated by Point.ToString(); to Point again? I save the string value in xml file in save mode and I want read it back to point again in read mode. var myStringWhichCantBeChanged="{X=-24,Y=10}"; var g=Regex.Replace(myStringWhichCantBeChanged,@"[\{\}a-zA-Z=]", "").Split(','); Point pointResult = new Point( int.Parse (g[0]), int.Parse( g[1])); System.Drawing.Point doesn't define a Parse method at all - you will need to write your own that can take this format and return a Point structure. System.Windows.Point does have a Parse method and may be