I'm trying to use the new excel integration module xlwings It works like a charm under Anaconda 2.0 for python 2.7 but I'm getting this error under Anaconda 2.0 for python 3.4 the xlwings file does contain class Workbook so I don't understand why it can't import it when I simply use the xlwings file in my project for 3.4 it works just fine
我试图使用新的excel集成模块xlwings它像一个魅力在蟒蛇python 2.0 2.0 2.0但我得到这个错误在蟒蛇python 3.4 xlwings文件包含类工作簿所以我不明白为什么它不能导入它当我在我的项目简单地使用xlwings文件3.4它工作得很好
File "C:\Users\xxxxx\AppData\Local\Continuum\Anaconda3\lib\site-packages\xlwings__init__.py", line 1, in from xlwings import Workbook, Range, Chart, version
用户文件“C:\ \ xxxxx \ AppData \当地\连续\ Anaconda3 \ lib \网站\ xlwings__init__。第1行,从xlwings导入工作簿,范围,图表,版本
ImportError: cannot import name 'Workbook'
ImportError:不能导入名称“工作簿”
1 个解决方案
#1
3
In "C:\Users\xxxxx\AppData\Local\Continuum\Anaconda3\lib\site-packages\xlwings__init__.py"
用户在“C:\ \ xxxxx \ AppData \当地\连续\ Anaconda3 \ lib \网站\ xlwings__init__.py”
Try changing from xlwings import Workbook, Range, Chart, __version__
尝试从xlwings导入工作簿、范围、图表、__version__。
to from xlwings.xlwings import Workbook, Range, Chart, __version__
从xlwings。进口工作簿、范围、图表、版本
#1
3
In "C:\Users\xxxxx\AppData\Local\Continuum\Anaconda3\lib\site-packages\xlwings__init__.py"
用户在“C:\ \ xxxxx \ AppData \当地\连续\ Anaconda3 \ lib \网站\ xlwings__init__.py”
Try changing from xlwings import Workbook, Range, Chart, __version__
尝试从xlwings导入工作簿、范围、图表、__version__。
to from xlwings.xlwings import Workbook, Range, Chart, __version__
从xlwings。进口工作簿、范围、图表、版本