Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Is there any C# library which can take a shapefile as an input with projection information defined (e.g, EPSG 3011) and return a new shapefile with user specified projection (e.g, EPSG 4326) ?

share|improve this question

GDAL/OGR has C# bindings. You might want to check it out. Alternatively, you might also want to check dotspatial. The dotspatial page has sample code on reprojecting a shape file.

You can do this in ogr ( It's provided in the FWTools package ). No need to code in C#.

ogr2ogr -s_srs EPSG:3011 -t_srs EPSG:4326 outfile.shp infile.shp

Thanks @iant for pointing it out.

share|improve this answer
OK! is there any piece of code you may know, which could take shapefile as an input ? – user1899 Feb 8 '12 at 13:40
ogr2ogr will do this – iant Feb 8 '12 at 14:19
@user1899 Why does it have to be a C# library btw? – R.K. Feb 8 '12 at 15:02
As i understand it is command line tool, But I need to change shapefile projection within my web C# application code. How I use ogr2ogr in my C# code? – user1899 Feb 8 '12 at 17:00
@user1899 Use the C# bindings for that. – R.K. Feb 9 '12 at 2:52

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.