[Gdal-dev] Define/overwrite projection on shapefile
Vikalpa Jetly
vjetly at i3.com
Fri Sep 15 11:11:02 EDT 2006
How would I use ogr to set/overwrite a projection for an existing shapefile?
I have a wkt projection say 'dref' that I want to use to set the projection.
I understand that while creating a new shapefile I can use:
sref = osr.SpatialReference()
sref.ImportFromWkt(dref)
layer = datasource.CreateLayer('newshape', geom_type=ogr.wkbPolygon, srs =
dref)
How would I do this for an existing shapefile? or do I need to create a copy
of the shapefile?
Thanks.
Vikalpa
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/gdal-dev/attachments/20060915/168ca6b7/attachment.html
More information about the Gdal-dev
mailing list