Hello

I'm trying to get the python bindings to the ogr library working with esri file 
geodatabase (filegdb) support.  I am using the latest version of ms4w package 
that includes gdal/ogr 1.9.

I have created a esri file geodatabase driver, then from that created a data 
source, but am unable to access layers from the data source object.  Below is a 
quick summary of my code:

    drvrObj = osgeo.ogr.GetDriverByName(r'FileGDB') # print the driver retunrs 
a SWIG object
    path = str(r'C:\testdatadir\arc10geodb.gdb')
    mydataSrc = drvrObj.Open(path) # printing the data source prints a SWIG 
object
    lyrCnt = mydataSrc.GetLayerCount() # always returns 0 but there are many 
layers in the fgdb
    lyr = mydataSrc.GetLayer(0) # always returns null

The comments in the code above kind of summarize the situation.  It appears 
that I can create a valid datasource but am unable to read the layers inside 
the datasource.  Any ideas?



_______________________________________________
gdal-dev mailing list
gdal-dev@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/gdal-dev

Reply via email to