Hello,
I'm new to Dot Spatial and really enthusiast to play with this great tool.
I am trying to convert lat/lng values to ETRS LAEA Europe coordinate system (EPSG:3035) but I always get NAN values (Not A Numeric). I think that this closed issue is probably the same: http://dotspatial.codeplex.com/workitem/22212
here is my code (VB.NET) :
```
Dim xy(1) As Double
xy(0) = 5
xy(1) = 50
Dim z(0) As Double
z(0) = 1
Dim pStart As ProjectionInfo = KnownCoordinateSystems.Geographic.World.WGS1984
Dim pEnd As ProjectionInfo = ProjectionInfo.FromProj4String("+proj=laea +lat_0=52 +lon_0=10 +x_0=4321000 +y_0=3210000 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs")
Try
Reproject.ReprojectPoints(xy, z, pStart, pEnd, 0, 1)
Catch ex As Exception
End Try
MsgBox("The points have been reporjected." & vbCrLf & xy(0) & "," & xy(1))
```
The code works well with other coordinate systems. It doesn't work with KnownCoordinateSystems.Projected.Europe.ETRS1989LAEA nor if I use the definition found in AuthorityCodeToProj4.txt (line 1006)
The Proj4 definition I use in the code is correct (verified in the epsg file of PROJ4).
Any idea?
Yvan
Comments: ** Comment from web user: IvanD79 **
I'm new to Dot Spatial and really enthusiast to play with this great tool.
I am trying to convert lat/lng values to ETRS LAEA Europe coordinate system (EPSG:3035) but I always get NAN values (Not A Numeric). I think that this closed issue is probably the same: http://dotspatial.codeplex.com/workitem/22212
here is my code (VB.NET) :
```
Dim xy(1) As Double
xy(0) = 5
xy(1) = 50
Dim z(0) As Double
z(0) = 1
Dim pStart As ProjectionInfo = KnownCoordinateSystems.Geographic.World.WGS1984
Dim pEnd As ProjectionInfo = ProjectionInfo.FromProj4String("+proj=laea +lat_0=52 +lon_0=10 +x_0=4321000 +y_0=3210000 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs")
Try
Reproject.ReprojectPoints(xy, z, pStart, pEnd, 0, 1)
Catch ex As Exception
End Try
MsgBox("The points have been reporjected." & vbCrLf & xy(0) & "," & xy(1))
```
The code works well with other coordinate systems. It doesn't work with KnownCoordinateSystems.Projected.Europe.ETRS1989LAEA nor if I use the definition found in AuthorityCodeToProj4.txt (line 1006)
The Proj4 definition I use in the code is correct (verified in the epsg file of PROJ4).
Any idea?
Yvan
Comments: ** Comment from web user: IvanD79 **
Same problem trying to convert from LAEA (3035) to WGS84 (4326), __it's a real BIG issue...__
For coordinates like, for example, 4175490.5731252655 - 1997066.9173578955 I receive NaN - NaN...
```
ProjectionInfo pStart = ProjectionInfo.FromEpsgCode(3035);
ProjectionInfo pEnd = KnownCoordinateSystems.Geographic.World.WGS1984;
SqlGeometry sqlPoint = sqlRing.STPointN(1);
double[] xy = new double[2];
xy[0] = sqlPoint.STX.Value;
xy[1] = sqlPoint.STY.Value;
Reproject.ReprojectPoints(xy, null, pStart, pEnd, 0, 1);
```