Opened 12 years ago

Closed 11 years ago

#301 closed defect (worksforme)

Problem running gdal*.py in osgeo4w shell

Reported by: vascobnunes Owned by: osgeo4w-dev@…
Priority: major Component: Package
Version: Keywords: osgeo4w, gdal

Description (last modified by maphew)

I'm trying to run (and other gdal*.py) from the Osgeo4w shell and can't do it cause I get this error:

Traceback (most recent call last):
  File "C:\OSGeo4W\\bin\", line 47, in <module>
    import gdal
  File "C:\OSGeo4W\apps\Python27\lib\site-packages\", line 2, in <module>
    from osgeo.gdal import deprecation_warn
  File "C:\OSGeo4W\apps\Python27\lib\site-packages\osgeo\", line 21,
in <module>
    _gdal = swig_import_helper()
  File "C:\OSGeo4W\apps\Python27\lib\site-packages\osgeo\", line 17,
in swig_import_helper
    _mod = imp.load_module('_gdal', fp, pathname, description)
ImportError: DLL load failed: The specified procedure could not be found.

Change History (2)

comment:1 by maphew, 12 years ago

Description: modified (diff)

It works for me at present. Perhaps your PATH environment isn't completely set, or there is something in it that shouldn't be (?)

From a fresh install of nothing but gdal-python and prerequisites, Start > Run > cmd then:



OSGEO4W home is c:\osgeo4w\

                   -={ OSGeo4W Shell Commands }=-


GDAL 1.9.1, released 2012/05/16

c:\>gdal_calc [-A <filename>] [--A_band] [-B...-Z filename]  [--calc <calculation>]
 [--format] [--outfile output_file] [--type data_type] [--NoDataValue] [--overwrite]


host system is Win7 Pro x64.

comment:2 by maphew, 11 years ago

Resolution: worksforme
Status: newclosed
Note: See TracTickets for help on using tickets.