From wxauto import *#导入当前微信客户端wx=WeChat()#导入会话列表wx。GetSessionList()#向某人发送消息(例如,“文件传输助手”)msg=' # file 2=' c 3360/users/administrator/desktoWho=“文件传输助手”wx。“ChatWith(who) #打开文件传输助手”聊天窗口# wx。sendmsg (msg) # wx。sendfiles(文件Wx .send files(file 1)for I inrange(10): #多次发送时,如果启用此代码行,则以下代码必须缩进4位才能使wx .SendMsg(msg)