前言
安装Python的Excel插件,在线安装,使用pip功能,
在线安装参考文章:pip工具安装与使用
离线安装参考:python中安装excel使用的模块
一、Excel插件xlrd安装
Excel的读取插件
安装命令:pip install xlrd
D:\vscode\Python38>pip install xlrd
Collecting xlrd
Downloading xlrd-1.2.0-py2.py3-none-any.whl (103 kB)
|████████████████████████████████| 103 kB 939 kB/s
Installing collected packages: xlrd
Successfully installed xlrd-1.2.0
二、Excel插件xlwt安装
Excel的写插件
安装命令:pip install xlwt
D:\vscode\Python38>pip install xlwt
Collecting xlwt
Downloading xlwt-1.3.0-py2.py3-none-any.whl (99 kB)
|████████████████████████████████| 99 kB 898 kB/s
Installing collected packages: xlwt
Successfully installed xlwt-1.3.0
问题处理
- 拷贝的python程序目录的修复
打开命令行窗口
cd d:\VSCode\python38
安装:python -m pip install pip
升级:python -m pip install --upgrade pip
D:\vscode\Python38>python -m pip install pip
Requirement already satisfied: pip in d:\vscode\python38\lib\site-packages (20.2.4)
D:\vscode\Python38>D:\vscode\Python38\python.exe -m pip install --upgrade pip
Requirement already up-to-date: pip in d:\vscode\python38\lib\site-packages (20.2.4)