Can I use the map object's addDataFromPath method to add data from a grib file?

12-30-2019 11:09 AM
New Contributor

I have tried, but get a RuntimeError.   Specifically, I am trying this in the python window of ArcGIS pro:

current_project ='CURRENT')

map = current_project.listMaps()[0]


It gives me a RuntimeError.  But if I use that same path in the GUI (Map -> Add Data -> Data From Path), it works fine.

Is the python method addDataFromPath not the same thing?  Should it work?  I've been semi-successful at adding a grib file to a map from the python window using arcpy.MakeRasterLayer_management, but that way seems to lose the time information, which I get if I just drag and drop the file into ArcGIS.

1 Reply
New Contributor III

Hi Jeff. I'm experiencing the same thing but when trying to add a feature class in the 'memory' workspace. Still no joy.

0 Kudos