pursue wind pursue wind
首页
Java
Python
数据库
框架
Linux
中间件
前端
计算机基础
DevOps
项目
面试
书
关于
归档
MacOS🤣 (opens new window)
GitHub (opens new window)
首页
Java
Python
数据库
框架
Linux
中间件
前端
计算机基础
DevOps
项目
面试
书
关于
归档
MacOS🤣 (opens new window)
GitHub (opens new window)
  • 基于Python轻松自建App服务器

    • 0App 与后端服务器通信方法简介
    • 1本小册要完成的通信场景功能
    • 2服务器端组件框架的选择与介绍
    • 3基于腾讯云的服务器端环境搭建
    • 4基于 Tornado 的 HTTP 服务器简介及代码组织框架
    • 5第一次数据请求 1:服务器接收用户注册信息
    • 6第一次数据请求 2:为用户处理模块增加 log 管理
    • 7第一次数据请求 3:将用户信息写入 MySQL 数据库
    • 8服务器接收客户端图片上传,并保存在硬盘中
    • 9服务器接收客户端请求,并返回 H5 页面
    • 10搭建基于 Nginx 的代理服务器
    • 11基于 HTTPS 的数据加密
    • 12大型 HTTP 服务器架构演进路线及思路
    • 13总结
  • 基于Python实现微信公众号爬虫

  • Xpath
  • python3 翻译
  • python3循环创建数据库表
  • python实用30个小技巧
  • pywin32
  • Python
pursuewind
2020-11-22

pywin32

import win32gui

hwnd_title = {}


def get_all_hwnd(hwnd, mouse):
    if win32gui.IsWindow(hwnd) and win32gui.IsWindowEnabled(hwnd) and win32gui.IsWindowVisible(hwnd):
        hwnd_title.update({hwnd: win32gui.GetWindowText(hwnd)})


e = win32gui.EnumWindows(get_all_hwnd, 0)
for window_handle, window_name in hwnd_title.items():
    if window_name == '此电脑':
        print(window_handle)
for window_handle, window_name in hwnd_title.items():
    if window_name:
        print(window_handle)

if __name__ == '__main__':
    pass
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
Last Updated: 2023/01/30, 11:01:00
python实用30个小技巧

← python实用30个小技巧

Theme by Vdoing | Copyright © 2019-2023 pursue-wind | 粤ICP备2022093130号
  • 跟随系统
  • 浅色模式
  • 深色模式
  • 阅读模式
  • 飙升榜
  • 新歌榜
  • 云音乐民谣榜
  • 美国Billboard榜
  • UK排行榜周榜
  • 网络DJ