随笔分类 -  python

摘要:很多时候需要通过webdriver获取我们所需要的东西 升级win自带浏览器至edge 找到edge版本: 进入:WebDriver-Microsoft 下载对应版本: 将下载后的文件解压,将解压后的msedgedriver.exe文件复制到python环境目录Scripts中 python 调用代 阅读全文
posted @ 2020-08-15 16:39 烟雨半生 阅读(4044) 评论(0) 推荐(0)
摘要: 阅读全文
posted @ 2020-07-05 20:45 烟雨半生 阅读(581) 评论(0) 推荐(0)
摘要:centos7 运行 session = requests_html.HTMLSession() h = session.get(url) # print(h.html) h.html.render() 报错: raise BadStatusLine(line)http.client.BadStat 阅读全文
posted @ 2020-06-06 13:42 烟雨半生 阅读(826) 评论(0) 推荐(0)
摘要:因为需要使用大漠插件 注册com组件能调用,但是免注册的没找到资料,故折腾了一番 #注册大漠插件 import win32com.client dm = win32com.client.Dispatch('dm.dmsoft') print(dm.Ver()) # 免注册大漠插件 import ct 阅读全文
posted @ 2019-11-06 19:17 烟雨半生 阅读(3369) 评论(0) 推荐(0)
摘要:今天用python 使用pyinstaller打包exe出现错误 环境pyqt5 + python3.6 32位 在导入pyqt5包之前加上如下代码 运行 96 INFO: PyInstaller: 3.597 INFO: Python: 3.6.497 INFO: Platform: Window 阅读全文
posted @ 2019-11-01 20:41 烟雨半生 阅读(2247) 评论(0) 推荐(0)
摘要:新装win7后安装python出现one or more issues caused the setup to fail . Please fix the issues and then retry setup.For more information see the log file 本次解决方法 阅读全文
posted @ 2019-10-19 13:30 烟雨半生 阅读(1680) 评论(0) 推荐(0)
摘要:1 ```python3 2 # 通过窗口类名、窗口标题获取控件句柄 3 hwnd = win32gui.FindWindow("ClassName", "TitleName") 4 # 通过句柄设置控件内容 5 win32gui.SendMessage(hwnd , 12, 0, '文本内容') 6 # 修改窗口标题 7 SetWindowText(hwnd, "Title") 8 #通过句柄获 阅读全文
posted @ 2019-10-10 12:59 烟雨半生 阅读(6150) 评论(0) 推荐(0)
摘要:```python3 enoding:utf 8 生成 buffer 对象 import win32con from win32gui import PyMakeBuffer, SendMessage, PyGetBufferAddressAndLen, PyGetString length = 1 阅读全文
posted @ 2019-05-24 10:08 烟雨半生 阅读(25701) 评论(9) 推荐(0)